Check for two state owner in simple task

This commit is contained in:
M66B
2019-07-31 10:10:59 +02:00
parent 59e3555bf7
commit a1f0418d03

View File

@@ -82,6 +82,9 @@ public abstract class SimpleTask<T> implements LifecycleObserver {
private void run(final Context context, final LifecycleOwner owner, final Bundle args, final String name) {
final Handler handler = new Handler();
if (owner instanceof TwoStateOwner)
Log.e(new Throwable("SimpleTask/TwoStateOwner"));
// prevent garbage collection
synchronized (tasks) {
tasks.add(this);