Skip to content

Commit ac1c59f

Browse files
committed
Merge branch 'feature/moving-nongen' into rsh/AzureIdentityAuth
2 parents 1c3fedd + abc2de4 commit ac1c59f

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

‎src/main/java/com/microsoft/graph/core/BaseClient.java‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,10 @@ public Builder<httpClientType, httpRequestType> authenticationProvider(@Nonnull
237237
* if there was an exception creating the client
238238
*/
239239
@Nonnull
240-
protected <ClientType extends BaseClient> ClientType buildClient(ClientType instance) throws ClientException {
240+
protected <ClientType extends BaseClient> ClientType buildClient(@Nonnull ClientType instance) throws ClientException {
241+
if(instance == null) {
242+
throw new IllegalArgumentException("The instance cannot be null");
243+
}
241244
instance.setHttpProvider(this.getHttpProvider());
242245
instance.setLogger(this.getLogger());
243246
instance.setSerializer(this.getSerializer());

0 commit comments

Comments
 (0)