That fuck shit the fascists are using
at master 52 lines 1.4 kB view raw
1package org.tm.archive.migrations; 2 3import androidx.annotation.NonNull; 4import androidx.annotation.Nullable; 5 6import org.tm.archive.dependencies.ApplicationDependencies; 7import org.tm.archive.jobmanager.Job; 8import org.tm.archive.jobs.StickerPackDownloadJob; 9import org.tm.archive.stickers.BlessedPacks; 10 11/** 12 * Installs Day by Day blessed pack. 13 */ 14public class StickerDayByDayMigrationJob extends MigrationJob { 15 16 public static final String KEY = "StickerDayByDayMigrationJob"; 17 18 StickerDayByDayMigrationJob() { 19 this(new Parameters.Builder().build()); 20 } 21 22 private StickerDayByDayMigrationJob(@NonNull Parameters parameters) { 23 super(parameters); 24 } 25 26 @Override 27 public boolean isUiBlocking() { 28 return false; 29 } 30 31 @Override 32 public @NonNull String getFactoryKey() { 33 return KEY; 34 } 35 36 @Override 37 public void performMigration() { 38 ApplicationDependencies.getJobManager().add(StickerPackDownloadJob.forInstall(BlessedPacks.DAY_BY_DAY.getPackId(), BlessedPacks.DAY_BY_DAY.getPackKey(), false)); 39 } 40 41 @Override 42 boolean shouldRetry(@NonNull Exception e) { 43 return false; 44 } 45 46 public static class Factory implements Job.Factory<StickerDayByDayMigrationJob> { 47 @Override 48 public @NonNull StickerDayByDayMigrationJob create(@NonNull Parameters parameters, @Nullable byte[] serializedData) { 49 return new StickerDayByDayMigrationJob(parameters); 50 } 51 } 52}