Skip to content

Commit 4621b1a

Browse files
Update MainApplication.kt
Signed-off-by: Androidacy Service Account <opensource@androidacy.com>
1 parent 5678753 commit 4621b1a

File tree

1 file changed

+16
-47
lines changed

1 file changed

+16
-47
lines changed

app/src/main/kotlin/com/fox2code/mmm/MainApplication.kt

Lines changed: 16 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -107,57 +107,26 @@ class MainApplication : Application(), Configuration.Provider, ActivityLifecycle
107107

108108
@Suppress("UnusedVariable")
109109
fun check(activity: AppCompatActivity) {
110-
val a = 0xFFFF and 0x7FFF
111-
val b = 0x1 shl 0x1 shl 0x1 shl 0x1 shl 0x1
112110
val d = BuildConfig.DEBUG
113-
val e = System.currentTimeMillis()
114-
val f = (e - (b * a * 180L)) > BuildConfig.BUILD_TIME
115-
val g = !d && f
116-
117-
@Suppress("ControlFlowWithEmptyBody") while (false);
118-
119-
if (g xor false) {
120-
val h = Intent(this, ExpiredActivity::class.java)
121-
val j = { s: String -> s.toCharArray() }
122-
if ((packageManager.queryIntentActivities(
123-
h,
124-
0
125-
).size and 0xFFFFFFFF.toInt()).toLong() != 0L
126-
) {
127-
startActivity(h)
111+
val t = System.currentTimeMillis()
112+
val ms = 86400000L
113+
val nd = 90 * 2
114+
val dd = 10 * 3
115+
val bt = BuildConfig.BUILD_TIME
116+
val ex = !d && (t > (bt + nd * ms))
117+
118+
if (ex) {
119+
val i = Intent(this, ExpiredActivity::class.java)
120+
i.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
121+
122+
if (packageManager.queryIntentActivities(i, 0).isNotEmpty()) {
123+
startActivity(i)
128124
activity.finish()
129125
} else {
130-
val m = String(ByteArray(22) { i ->
131-
byteArrayOf(
132-
84,
133-
104,
134-
105,
135-
115,
136-
32,
137-
98,
138-
117,
139-
105,
140-
108,
141-
100,
142-
32,
143-
104,
144-
97,
145-
115,
146-
32,
147-
101,
148-
120,
149-
112,
150-
105,
151-
114,
152-
101,
153-
100
154-
)[i]
155-
})
156-
throw IllegalAccessError(m)
126+
throw IllegalAccessError("e1")
157127
}
158-
} else if (d && (e - (b * a * 30L)) > BuildConfig.BUILD_TIME) {
159-
Toast.makeText(this, resources.getText(R.string.build_expired), Toast.LENGTH_LONG)
160-
.show()
128+
} else if (d && (t > (bt + dd * ms))) {
129+
Toast.makeText(this, resources.getText(R.string.build_expired), Toast.LENGTH_LONG).show()
161130
}
162131
}
163132

0 commit comments

Comments
 (0)