Skip to content

Commit

Permalink
fix: wrong auto updater file
Browse files Browse the repository at this point in the history
  • Loading branch information
rhunk committed Jun 5, 2023
1 parent 657cdc6 commit b00d671
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ class RootBridgeClient : AbstractBridgeClient() {
}

override fun getAutoUpdaterTime(): Long {
readFile(BridgeFileType.ANTI_AUTO_DOWNLOAD).run {
readFile(BridgeFileType.AUTO_UPDATER_TIMESTAMP).run {
return if (isEmpty()) {
0
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ class ServiceBridgeClient: AbstractBridgeClient(), ServiceConnection {
}

override fun getAutoUpdaterTime(): Long {
readFile(BridgeFileType.ANTI_AUTO_DOWNLOAD).run {
createAndReadFile(BridgeFileType.AUTO_UPDATER_TIMESTAMP, "0".toByteArray()).run {
return if (isEmpty()) {
0
} else {
Expand All @@ -232,7 +232,7 @@ class ServiceBridgeClient: AbstractBridgeClient(), ServiceConnection {
}

override fun setAutoUpdaterTime(time: Long) {
writeFile(BridgeFileType.ANTI_AUTO_DOWNLOAD, time.toString().toByteArray())
writeFile(BridgeFileType.AUTO_UPDATER_TIMESTAMP, time.toString().toByteArray())
}

override fun onServiceConnected(name: ComponentName, service: IBinder) {
Expand Down

0 comments on commit b00d671

Please sign in to comment.