mirror of
https://github.com/mitb-archive/filebot
synced 2024-12-24 16:58:51 -05:00
Refactor
This commit is contained in:
parent
360e0b5a55
commit
535a16621c
@ -27,13 +27,11 @@ class MemoizedResource<R> implements Resource<R> {
|
||||
}
|
||||
|
||||
@Override
|
||||
public R get() throws Exception {
|
||||
synchronized (resource) {
|
||||
if (value == null) {
|
||||
value = resource.get();
|
||||
}
|
||||
return value;
|
||||
public synchronized R get() throws Exception {
|
||||
if (value == null) {
|
||||
value = resource.get();
|
||||
}
|
||||
return value;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user