Show More
@@ -114,21 +114,27 b' class filectx(object):' | |||
|
114 | 114 | |
|
115 | 115 | if filelog: |
|
116 | 116 | self._filelog = filelog |
|
117 | else: | |
|
118 | self._filelog = self._repo.file(self._path) | |
|
119 | 117 | |
|
120 | 118 | if fileid is None: |
|
121 | 119 | self._changeid = changeid |
|
122 | 120 | else: |
|
123 |
self._file |
|
|
124 | self._changeid = self._filelog.linkrev(self._filenode) | |
|
121 | self._fileid = fileid | |
|
125 | 122 | |
|
126 | 123 | def __getattr__(self, name): |
|
127 | 124 | if name == '_changectx': |
|
128 | 125 | self._changectx = changectx(self._repo, self._changeid) |
|
129 | 126 | return self._changectx |
|
127 | elif name == '_filelog': | |
|
128 | self._filelog = self._repo.file(self._path) | |
|
129 | return self._filelog | |
|
130 | elif name == '_changeid': | |
|
131 | self._changeid = self._filelog.linkrev(self._filenode) | |
|
132 | return self._changeid | |
|
130 | 133 | elif name == '_filenode': |
|
131 | self._filenode = self._changectx.filenode(self._path) | |
|
134 | if hasattr(self, "_fileid"): | |
|
135 | self._filenode = self._filelog.lookup(self._fileid) | |
|
136 | else: | |
|
137 | self._filenode = self._changectx.filenode(self._path) | |
|
132 | 138 | return self._filenode |
|
133 | 139 | elif name == '_filerev': |
|
134 | 140 | self._filerev = self._filelog.rev(self._filenode) |
General Comments 0
You need to be logged in to leave comments.
Login now