@@ 1189-1193 (lines=5) @@ | ||
1186 | $result = $storage->$operation($internalPath); |
|
1187 | } |
|
1188 | } catch (\Exception $e) { |
|
1189 | if (\in_array('write', $hooks) || \in_array('delete', $hooks)) { |
|
1190 | $this->unlockFile($path, ILockingProvider::LOCK_EXCLUSIVE); |
|
1191 | } elseif (\in_array('read', $hooks)) { |
|
1192 | $this->unlockFile($path, ILockingProvider::LOCK_SHARED); |
|
1193 | } |
|
1194 | throw $e; |
|
1195 | } |
|
1196 | ||
@@ 1231-1235 (lines=5) @@ | ||
1228 | } |
|
1229 | } |
|
1230 | ||
1231 | if (!$unlockLater |
|
1232 | && (\in_array('write', $hooks) || \in_array('delete', $hooks) || \in_array('read', $hooks)) |
|
1233 | ) { |
|
1234 | $this->unlockFile($path, ILockingProvider::LOCK_SHARED); |
|
1235 | } |
|
1236 | return $result; |
|
1237 | } else { |
|
1238 | $this->unlockFile($path, ILockingProvider::LOCK_SHARED); |