Skip to content

Commit 7d408e1

Browse files
nkolosnjajimp911de
authored andcommitted
Fix typos in GcpIamAuthenticationOptions and GcpIamCredentialsAuthenticationOptions.
See gh-657
1 parent a3e9c0c commit 7d408e1

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

spring-vault-core/src/main/java/org/springframework/vault/authentication/GcpIamAuthenticationOptions.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ public GcpIamAuthenticationOptionsBuilder role(String role) {
249249
*/
250250
public GcpIamAuthenticationOptionsBuilder jwtValidity(Duration jwtValidity) {
251251

252-
Assert.hasText(this.role, "JWT validity duration must not be null");
252+
Assert.notNull(jwtValidity, "JWT validity duration must not be null");
253253

254254
this.jwtValidity = jwtValidity;
255255
return this;
@@ -263,7 +263,7 @@ public GcpIamAuthenticationOptionsBuilder jwtValidity(Duration jwtValidity) {
263263
*/
264264
public GcpIamAuthenticationOptionsBuilder clock(Clock clock) {
265265

266-
Assert.hasText(this.role, "Clock must not be null");
266+
Assert.notNull(clock, "Clock must not be null");
267267

268268
this.clock = clock;
269269
return this;

spring-vault-core/src/main/java/org/springframework/vault/authentication/GcpIamCredentialsAuthenticationOptions.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ public GcpIamCredentialsAuthenticationOptionsBuilder role(String role) {
200200
*/
201201
public GcpIamCredentialsAuthenticationOptionsBuilder jwtValidity(Duration jwtValidity) {
202202

203-
Assert.hasText(this.role, "JWT validity duration must not be null");
203+
Assert.notNull(jwtValidity, "JWT validity duration must not be null");
204204

205205
this.jwtValidity = jwtValidity;
206206
return this;
@@ -214,7 +214,7 @@ public GcpIamCredentialsAuthenticationOptionsBuilder jwtValidity(Duration jwtVal
214214
*/
215215
public GcpIamCredentialsAuthenticationOptionsBuilder clock(Clock clock) {
216216

217-
Assert.hasText(this.role, "Clock must not be null");
217+
Assert.notNull(clock, "Clock must not be null");
218218

219219
this.clock = clock;
220220
return this;

0 commit comments

Comments
 (0)