diff options
| author | Josh Ferrell <josh@vector35.com> | 2022-12-22 14:54:19 -0500 |
|---|---|---|
| committer | Josh Ferrell <josh@vector35.com> | 2022-12-22 15:20:27 -0500 |
| commit | b5124b220868851108193f44b9111d4039ff7b12 (patch) | |
| tree | f66774a0da998e09cefd4efb2fab2ae4089ff395 /python/filemetadata.py | |
| parent | d0b71355485126d15389f9f2de201cc154e19c69 (diff) | |
Fix many incorrect type hints and type errors
Diffstat (limited to 'python/filemetadata.py')
| -rw-r--r-- | python/filemetadata.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/python/filemetadata.py b/python/filemetadata.py index ca5645ab..0335e9bc 100644 --- a/python/filemetadata.py +++ b/python/filemetadata.py @@ -416,8 +416,8 @@ class FileMetadata: return core.BNNavigate(self.handle, str(view), offset) def create_database( - self, filename: str, progress_func: Optional[ProgressFuncType] = None, settings: SaveSettings = None - ): + self, filename: str, progress_func: Optional[ProgressFuncType] = None, settings: Optional[SaveSettings] = None + ) -> bool: """ ``create_database`` writes the current database (.bndb) out to the specified file. @@ -446,7 +446,7 @@ class FileMetadata: ctypes.c_ulonglong)(lambda ctxt, cur, total: _progress_func(cur, total)), _settings ) - def open_existing_database(self, filename: str, progress_func: Callable[[int, int], bool] = None): + def open_existing_database(self, filename: str, progress_func: Optional[Callable[[int, int], bool]] = None): if progress_func is None: view = core.BNOpenExistingDatabase(self.handle, str(filename)) else: @@ -465,7 +465,7 @@ class FileMetadata: return None return binaryview.BinaryView(file_metadata=self, handle=view) - def save_auto_snapshot(self, progress_func: Optional[ProgressFuncType] = None, settings: SaveSettings = None): + def save_auto_snapshot(self, progress_func: Optional[ProgressFuncType] = None, settings: Optional[SaveSettings] = None) -> bool: _settings = None if settings is not None: _settings = settings.handle |
