mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-30 00:32:30 +08:00
Fix IDE warnings (#12281)
### What problem does this PR solve? As title ### Type of change - [x] Refactoring --------- Signed-off-by: Jin Hai <haijin.chn@gmail.com>
This commit is contained in:
@ -42,14 +42,16 @@ class RAGFlowOSS:
|
||||
# If there is a default bucket, use the default bucket
|
||||
actual_bucket = self.bucket if self.bucket else bucket
|
||||
return method(self, actual_bucket, *args, **kwargs)
|
||||
|
||||
return wrapper
|
||||
|
||||
|
||||
@staticmethod
|
||||
def use_prefix_path(method):
|
||||
def wrapper(self, bucket, fnm, *args, **kwargs):
|
||||
# If the prefix path is set, use the prefix path
|
||||
fnm = f"{self.prefix_path}/{fnm}" if self.prefix_path else fnm
|
||||
return method(self, bucket, fnm, *args, **kwargs)
|
||||
|
||||
return wrapper
|
||||
|
||||
def __open__(self):
|
||||
@ -171,4 +173,3 @@ class RAGFlowOSS:
|
||||
self.__open__()
|
||||
time.sleep(1)
|
||||
return None
|
||||
|
||||
|
||||
Reference in New Issue
Block a user