Custom JobIntentService onHandleWork not called

前端 未结 12 1250
-上瘾入骨i
-上瘾入骨i 2020-12-09 08:27

I recently was updating an app that I work on to handle notifications from push using a JobIntentService instead of a regular IntentService because

12条回答
  •  慢半拍i
    慢半拍i (楼主)
    2020-12-09 08:36

    This is what worked for me,

    Remove the IBind Override as suggested by @agirardello

    and added the following

    @Override
    public int onStartCommand(@Nullable Intent intent, int flags, int startId) {
        return super.onStartCommand(intent, flags, startId);
    }
    

    Have no idea why this worked.

提交回复
热议问题