mirror of
https://github.com/topjohnwu/Magisk.git
synced 2026-01-15 14:24:15 -08:00
Don't need to wrap another layer of context
This commit is contained in:
@@ -6,7 +6,6 @@ import androidx.annotation.NonNull;
|
||||
import androidx.work.Worker;
|
||||
import androidx.work.WorkerParameters;
|
||||
|
||||
import com.topjohnwu.magisk.HacksKt;
|
||||
import com.topjohnwu.magisk.base.DelegateWorker;
|
||||
|
||||
import java.lang.reflect.ParameterizedType;
|
||||
@@ -19,7 +18,7 @@ public abstract class w<T extends DelegateWorker> extends Worker {
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
w(@NonNull Context context, @NonNull WorkerParameters workerParams) {
|
||||
super(HacksKt.wrap(context, false), workerParams);
|
||||
super(context, workerParams);
|
||||
try {
|
||||
base = ((Class<T>) ((ParameterizedType) getClass().getGenericSuperclass())
|
||||
.getActualTypeArguments()[0]).newInstance();
|
||||
|
||||
Reference in New Issue
Block a user