Ticket #16964: patch.diff
File patch.diff, 565 bytes (added by , 13 years ago) |
---|
-
django/core/files/base.py
diff --git a/django/core/files/base.py b/django/core/files/base.py index 6204d71..722324a 100644
a b class File(FileProxyMixin): 108 108 self.close() 109 109 110 110 def open(self, mode=None): 111 if not self.closed: 112 self.seek(0) 113 elif self.name and os.path.exists(self.name): 111 if self.name and os.path.exists(self.name): 114 112 self.file = open(self.name, mode or self.mode) 115 113 else: 116 114 raise ValueError("The file cannot be reopened.")