From 4a3d0c5c84a6a92f2a660df27cffba3d3b83b56a Mon Sep 17 00:00:00 2001 From: brettlangdon Date: Fri, 24 Aug 2018 20:06:33 -0400 Subject: [PATCH] Fix linting issues --- importhook/__init__.py | 2 +- importhook/finder.py | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/importhook/__init__.py b/importhook/__init__.py index 95b93a1..b5a5738 100644 --- a/importhook/__init__.py +++ b/importhook/__init__.py @@ -123,7 +123,7 @@ def copy_module(module, copy_attributes=True, copy_spec=True): name = get_module_name(module) new_mod = types.ModuleType(name) setattr(new_mod, '__original_module__', module) - setattr(new_mod, '__reset_module__', lambda: uncopy_module(name)) + setattr(new_mod, '__reset_module__', lambda: reset_module(name)) # Copy all module attributes if copy_attributes: diff --git a/importhook/finder.py b/importhook/finder.py index 7b2244b..c016e76 100644 --- a/importhook/finder.py +++ b/importhook/finder.py @@ -1,4 +1,3 @@ -from importlib.abc import MetaPathFinder import functools from .loader import HookLoader @@ -14,7 +13,7 @@ def hook_finder(finder): """ # If this finder has already been 'hooked', then return as-is if hasattr(finder, '__hooked__'): - return finder; + return finder # Determine if we were given an instance or a class if isinstance(finder, type):