Skip to content

Commit e58a6e7

Browse files
committed
Fix deprecated Log calls
1 parent c36bafe commit e58a6e7

2 files changed

Lines changed: 7 additions & 7 deletions

File tree

android/sdl_android/src/main/java/com/smartdevicelink/transport/SdlBroadcastReceiver.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -289,15 +289,15 @@ public void onComplete(Vector<ComponentName> routerServices) {
289289
if (sdlAppInfoList != null && !sdlAppInfoList.isEmpty() && sdlAppInfoList.get(0).getRouterServiceComponentName() != null) {
290290
routerServicePackage = sdlAppInfoList.get(0).getRouterServiceComponentName().getPackageName();
291291
}
292-
DebugTool.logInfo(TAG + ": This app's package: " + myPackage);
293-
DebugTool.logInfo(TAG + ": Router service app's package: " + routerServicePackage);
292+
DebugTool.logInfo(TAG, ": This app's package: " + myPackage);
293+
DebugTool.logInfo(TAG, ": Router service app's package: " + routerServicePackage);
294294
if (myPackage != null && myPackage.equalsIgnoreCase(routerServicePackage)) {
295295
SdlDeviceListener sdlDeviceListener = getSdlDeviceListener(context, device);
296296
if (!sdlDeviceListener.isRunning()) {
297297
sdlDeviceListener.start();
298298
}
299299
} else {
300-
DebugTool.logInfo(TAG + ": Not the app to start the router service nor device listener");
300+
DebugTool.logInfo(TAG, ": Not the app to start the router service nor device listener");
301301
}
302302
return;
303303
}

android/sdl_android/src/main/java/com/smartdevicelink/transport/utl/SdlDeviceListener.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,15 +85,15 @@ public SdlDeviceListener(Context context, BluetoothDevice device, Callback callb
8585
*/
8686
public void start() {
8787
if(connectedDevice == null) {
88-
DebugTool.logInfo(TAG + ": No supplied bluetooth device");
88+
DebugTool.logInfo(TAG, ": No supplied bluetooth device");
8989
if(callback != null){
9090
callback.onTransportError(null);
9191
}
9292
return;
9393
}
9494

9595
if (hasSDLConnected(contextWeakReference.get(), connectedDevice.getAddress())) {
96-
DebugTool.logInfo(TAG + ": Confirmed SDL device, should start router service");
96+
DebugTool.logInfo(TAG, ": Confirmed SDL device, should start router service");
9797
//This device has connected to SDL previously, it is ok to start the RS right now
9898
callback.onTransportConnected(contextWeakReference.get(), connectedDevice);
9999
return;
@@ -113,7 +113,7 @@ public void run() {
113113
if (bluetoothTransport != null) {
114114
int state = bluetoothTransport.getState();
115115
if (state != MultiplexBluetoothTransport.STATE_CONNECTED) {
116-
DebugTool.logInfo(TAG + ": No bluetooth connection made");
116+
DebugTool.logInfo(TAG, ": No bluetooth connection made");
117117
bluetoothTransport.stop();
118118
} //else BT is connected; it will close itself through callbacks
119119
}
@@ -188,7 +188,7 @@ public void handleMessage(@NonNull Message msg) {
188188
public static void setSDLConnectedStatus(Context context, String address, boolean hasSDLConnected) {
189189
synchronized (LOCK) {
190190
if (context != null) {
191-
DebugTool.logInfo(TAG + ": Saving connected status - " + address + " : " + hasSDLConnected);
191+
DebugTool.logInfo(TAG, ": Saving connected status - " + address + " : " + hasSDLConnected);
192192
SharedPreferences preferences = context.getSharedPreferences(SDL_DEVICE_STATUS_SHARED_PREFS, Context.MODE_PRIVATE);
193193
if (preferences.contains(address) && hasSDLConnected == preferences.getBoolean(address, false)) {
194194
//The same key/value exists in our shared preferences. No reason to write again.

0 commit comments

Comments
 (0)