mirror of
https://github.com/advplyr/audiobookshelf-app.git
synced 2025-08-02 17:14:29 +02:00
Changed network connection check logic
Network connection no longer requires internet connection. Socket connection status is used instead for checking if server is reachable. If there is no socket connection available eq. before connecting to server then connection type is used to for netrork connection check.
This commit is contained in:
parent
f7663fc17f
commit
fe9168c6cf
4 changed files with 29 additions and 25 deletions
|
@ -101,8 +101,8 @@ export default {
|
|||
isAdminOrUp() {
|
||||
return this.$store.getters['user/getIsAdminOrUp']
|
||||
},
|
||||
networkConnected() {
|
||||
return this.$store.state.networkConnected
|
||||
socketConnected() {
|
||||
return this.$store.state.socketConnected
|
||||
},
|
||||
libraryItemId() {
|
||||
return this.libraryItem?.id || null
|
||||
|
@ -233,7 +233,7 @@ export default {
|
|||
}
|
||||
},
|
||||
async searchEpisodes() {
|
||||
if (!this.networkConnected) {
|
||||
if (!this.socketConnected) {
|
||||
return this.$toast.error(this.$strings.MessageNoNetworkConnection)
|
||||
}
|
||||
|
||||
|
@ -314,4 +314,4 @@ export default {
|
|||
this.$socket.$off('episode_download_finished', this.episodeDownloadFinished)
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue