public static KickflipApiClient getApiClient ( Context context , KickflipCallback callback ) { checkNotNull ( sClientKey ) ; checkNotNull ( sClientSecret ) ; if ( sKickflip == null || ! sKickflip . getConfig ( ) . getClientId ( ) . equals ( sClientKey ) ) { sKickflip = new KickflipApiClient ( context , sClientKey , sClientSecret , callback ) ; } else if ( callback != null ) { callback . onSuccess ( sKickflip . getActiveUser ( ) ) ; } return sKickflip ; }
Create a new instance of the KickflipApiClient if one hasn t yet been created or the provided API keys don t match the existing client .