File tree Expand file tree Collapse file tree 2 files changed +4
-5
lines changed
eternalcore-core/src/main/java/com/eternalcode/core/feature/warp Expand file tree Collapse file tree 2 files changed +4
-5
lines changed Original file line number Diff line number Diff line change 8
8
import java .util .Collections ;
9
9
import java .util .List ;
10
10
11
- @ SuppressWarnings ("LombokSetterMayBeUsed" )
12
11
public class WarpImpl implements Warp {
13
12
14
13
private final String name ;
15
14
private final Position position ;
16
- private List <String > permissions ;
15
+ private final List <String > permissions ;
17
16
18
17
public WarpImpl (String name , Position position , List <String > permissions ) {
19
18
this .name = name ;
Original file line number Diff line number Diff line change @@ -97,17 +97,17 @@ private void migrateWarps() {
97
97
}
98
98
}
99
99
100
- private CompletableFuture <Void > transactionalRun (Consumer <Map <String , WarpDataConfigRepresenter >> editor ) {
100
+ private CompletableFuture <Void > transactionalRun (Consumer <Map <String , WarpConfigRepresenter >> editor ) {
101
101
return transactionalSupply (warps -> {
102
102
editor .accept (warps );
103
103
return null ;
104
104
});
105
105
}
106
106
107
- private <T > CompletableFuture <T > transactionalSupply (Function <Map <String , WarpDataConfigRepresenter >, T > editor ) {
107
+ private <T > CompletableFuture <T > transactionalSupply (Function <Map <String , WarpConfigRepresenter >, T > editor ) {
108
108
return scheduler .completeAsync (() -> {
109
109
synchronized (READ_WRITE_LOCK ) {
110
- Map <String , WarpDataConfigRepresenter > warps = new HashMap <>(this .warpDataConfig .warps );
110
+ Map <String , WarpConfigRepresenter > warps = new HashMap <>(this .warpDataConfig .warps );
111
111
T result = editor .apply (warps );
112
112
this .warpDataConfig .warps .putAll (warps );
113
113
this .configurationManager .save (this .warpDataConfig );
You can’t perform that action at this time.
0 commit comments