Skip to content

Commit 522aff1

Browse files
committed
reactivate lock but rename variable
1 parent fc0db21 commit 522aff1

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

activestorage/active.py

+7-7
Original file line numberDiff line numberDiff line change
@@ -158,16 +158,16 @@ def __getitem__(self, index):
158158

159159
elif self._version == 2:
160160
# No active operation either
161-
#lock = self.lock
162-
#if lock:
163-
# lock.acquire()
161+
lock = self.lock
162+
if lock:
163+
lock.acquire()
164164

165-
data = self._via_kerchunk(index)
165+
data_2 = self._via_kerchunk(index)
166166

167-
#if lock:
168-
# lock.release()
167+
if lock:
168+
lock.release()
169169

170-
return data
170+
return data_2
171171

172172
else:
173173
raise ValueError(f'Version {self._version} not supported')

0 commit comments

Comments
 (0)