def normalize_playable_path(self, path): if '://' in path: return path if not os.path.isabs(path): return os.path.normpath(os.path.join(self.parent.path, path)) if check_under_base(path, self.app.config['directory_base']): return os.path.normpath(path) return None
def normalize_playable_path(self, path): if "://" in path: return path path = os.path.normpath(path) if not os.path.isabs(path): return os.path.join(self.parent.path, path) drive = os.path.splitdrive(self.path)[0] if drive and not os.path.splitdrive(path)[0]: path = drive + path if check_under_base(path, self.app.config["directory_base"]): return path return None
def normalize_playable_path(self, path): if '://' in path: return path path = os.path.normpath(path) if not os.path.isabs(path): return os.path.join(self.parent.path, path) drive = os.path.splitdrive(self.path)[0] if drive and not os.path.splitdrive(path)[0]: path = drive + path if check_under_base(path, self.app.config['directory_base']): return path return None