File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed
core/src/main/java/com/datastax/oss/driver/internal/core Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change 21
21
import com .datastax .oss .driver .api .core .config .DriverExecutionProfile ;
22
22
import com .datastax .oss .driver .api .core .config .DriverOption ;
23
23
import com .datastax .oss .driver .internal .core .util .Loggers ;
24
- import com .datastax .oss .driver .shaded .guava .common .base .Preconditions ;
25
24
import com .datastax .oss .driver .shaded .guava .common .collect .ImmutableMap ;
26
25
import com .typesafe .config .Config ;
27
26
import com .typesafe .config .ConfigObject ;
@@ -152,7 +151,10 @@ public DriverExecutionProfile getProfile(@NonNull String profileName) {
152
151
return defaultProfile ;
153
152
}
154
153
return Optional .ofNullable (profiles .get (profileName ))
155
- .orElseThrow (() -> new IllegalArgumentException (String .format ("Unknown profile '%s'. Check your configuration." , profileName )));
154
+ .orElseThrow (
155
+ () ->
156
+ new IllegalArgumentException (
157
+ String .format ("Unknown profile '%s'. Check your configuration." , profileName )));
156
158
}
157
159
158
160
@ NonNull
Original file line number Diff line number Diff line change @@ -76,7 +76,7 @@ public List<Integer> allIndicesOf(String name) {
76
76
*/
77
77
public int firstIndexOf (String name ) {
78
78
Iterator <Integer > indices = allIndicesOf (name ).iterator ();
79
- return indices .hasNext () ? - 1 : indices .next ();
79
+ return indices .hasNext () ? indices .next () : - 1 ;
80
80
}
81
81
82
82
/** Returns all occurrences of a given identifier. */
@@ -87,6 +87,6 @@ public List<Integer> allIndicesOf(CqlIdentifier id) {
87
87
/** Returns the first occurrence of a given identifier, or -1 if it's not in the list. */
88
88
public int firstIndexOf (CqlIdentifier id ) {
89
89
Iterator <Integer > indices = allIndicesOf (id ).iterator ();
90
- return indices .hasNext () ? - 1 : indices .next ();
90
+ return indices .hasNext () ? indices .next () : - 1 ;
91
91
}
92
92
}
You can’t perform that action at this time.
0 commit comments