File tree Expand file tree Collapse file tree 2 files changed +9
-2
lines changed
Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -112,6 +112,11 @@ export default class Account {
112112
113113 let mappings = await this . storage . getMappings ( )
114114 await this . tree . load ( mappings )
115+
116+ if ( Object . keys ( mappings . LocalToServer ) . length === 0 && this . tree . getAllBookmarks ( ) . length !== 0 ) {
117+ await this . setData ( { ...this . getData ( ) , syncing : 'initial' } )
118+ }
119+
115120 // Deletes things we've known but that are no longer there locally
116121 await this . sync_deleteFromServer ( mappings )
117122 // Server handles existing URLs that we think are new, client handles new URLs that are bookmarked twice locally
Original file line number Diff line number Diff line change @@ -48,7 +48,7 @@ export default class NextcloudAdapter {
4848 < td > < input value = { new InputInitializeHook ( data . password ) } type = "password" className = "password" name = "password" ev-keydown = { onchangePassword } ev-blur = { onchangePassword } /> </ td > </ tr >
4949 < tr > < td > </ td > < td >
5050 < span className = "status" > {
51- data . syncing === true
51+ data . syncing
5252 ? '↻ Syncing...'
5353 : ( data . error
5454 ? < span > ✘ Error!</ span >
@@ -68,7 +68,9 @@ export default class NextcloudAdapter {
6868 < a href = "#" className = { 'btn forceSync ' + ( data . syncing ? 'disabled' : '' ) } ev-click = { ( ) => ! data . syncing && ctl . sync ( ) } > Sync now</ a >
6969 < div className = "status-details" > { data . error
7070 ? data . error
71- : 'Last synchronized: ' + ( data . lastSync ? humanizeDuration ( Date . now ( ) - data . lastSync , { largest : 1 , round : true } ) + ' ago' : 'never' ) } </ div >
71+ : data . syncing === 'initial'
72+ ? 'Syncing from scratch. This may take a longer than usual...'
73+ : 'Last synchronized: ' + ( data . lastSync ? humanizeDuration ( Date . now ( ) - data . lastSync , { largest : 1 , round : true } ) + ' ago' : 'never' ) } </ div >
7274 < div className = "options" >
7375 < formgroup >
7476 < h4 > Sync folder</ h4 >
You can’t perform that action at this time.
0 commit comments