Merge pull request #59 from GeMotionX/patch-4

Update SpiceUploadReceiver.java
This commit is contained in:
Mariotaku 2015-03-05 22:18:29 +08:00
commit 82fea84df2
1 changed files with 0 additions and 6 deletions

View File

@ -25,12 +25,6 @@ public class SpiceUploadReceiver extends BroadcastReceiver {
final boolean isWifi = Utils.isOnWifi(context.getApplicationContext());
final boolean isCharging = SpiceProfilingUtil.isCharging(context.getApplicationContext());
if (WifiManager.SUPPLICANT_CONNECTION_CHANGE_ACTION.equals(action)) {
final boolean wifi = intent.getBooleanExtra(WifiManager.EXTRA_SUPPLICANT_CONNECTED, false);
SpiceProfilingUtil.profile(context, SpiceProfilingUtil.FILE_NAME_WIFI, wifi ? "connected" : "disconnected");
SpiceProfilingUtil.log(context, wifi ? "connected" : "disconnected" );
}
if (isWifi && isCharging) {
new SpiceAsyUploadTask(context).execute();
}