diff --git a/etiquette/helpers.py b/etiquette/helpers.py index 8fa5e11..d57541b 100644 --- a/etiquette/helpers.py +++ b/etiquette/helpers.py @@ -329,7 +329,7 @@ def read_filebytes(filepath, range_min=0, range_max=None, chunk_size=bytestring. range_max = filepath.size range_span = (range_max + 1) - range_min - f = open(filepath.absolute_path, 'rb') + f = filepath.open('rb') sent_amount = 0 with f: f.seek(range_min) diff --git a/etiquette/photodb.py b/etiquette/photodb.py index 4805113..f7825e6 100644 --- a/etiquette/photodb.py +++ b/etiquette/photodb.py @@ -1826,7 +1826,7 @@ class PhotoDB( self.save_config() def save_config(self): - with open(self.config_filepath.absolute_path, 'w', encoding='utf-8') as handle: + with self.config_filepath.open('w', encoding='utf-8') as handle: handle.write(json.dumps(self.config, indent=4, sort_keys=True)) if __name__ == '__main__':