Skip to content

Commit

Permalink
Merge pull request #352 from TakayukiHoshi1984/bugfix_sphero_bluetoot…
Browse files Browse the repository at this point in the history
…h_name_null

SpheroプラグインにてBluetooth名がnullのデバイスがペアリングされている場合の不具合修正
  • Loading branch information
TakayukiHoshi1984 committed Sep 26, 2017
2 parents e8a4655 + 7eb198b commit e3a0324
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion dConnectDevicePlugin/dConnectDeviceSphero/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ android {
}
defaultConfig {
applicationId "org.deviceconnect.android.deviceplugin.sphero"
minSdkVersion 14
minSdkVersion 18
targetSdkVersion 23
versionCode 1
versionName getVersionName()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ public void onCreate() {
BluetoothAdapter adapter = BluetoothAdapter.getDefaultAdapter();
Set<BluetoothDevice> pairedDevices = adapter.getBondedDevices();
for (BluetoothDevice device : pairedDevices) {
if (device.getName().contains("Sphero")) {
if (device.getName() != null && device.getName().contains("Sphero")) {
PermissionUtility.requestPermissions(SpheroDeviceService.this, mHandler,
BleUtils.BLE_PERMISSIONS,
new PermissionUtility.PermissionRequestCallback() {
Expand Down

0 comments on commit e3a0324

Please sign in to comment.