kopia lustrzana https://github.com/nolanlawson/pinafore
				
				
				
			fix another indexeddb migration bug
							rodzic
							
								
									ad36d9274d
								
							
						
					
					
						commit
						4d386357e7
					
				| 
						 | 
				
			
			@ -1,12 +1,12 @@
 | 
			
		|||
export const STATUSES_STORE = 'statuses-v3'
 | 
			
		||||
export const STATUS_TIMELINES_STORE = 'status_timelines-v3'
 | 
			
		||||
export const META_STORE = 'meta-v3'
 | 
			
		||||
export const ACCOUNTS_STORE = 'accounts-v3'
 | 
			
		||||
export const RELATIONSHIPS_STORE = 'relationships-v3'
 | 
			
		||||
export const NOTIFICATIONS_STORE = 'notifications-v3'
 | 
			
		||||
export const NOTIFICATION_TIMELINES_STORE = 'notification_timelines-v3'
 | 
			
		||||
export const PINNED_STATUSES_STORE = 'pinned_statuses-v3'
 | 
			
		||||
export const THREADS_STORE = 'threads-v3'
 | 
			
		||||
export const STATUSES_STORE = 'statuses-v4'
 | 
			
		||||
export const STATUS_TIMELINES_STORE = 'status_timelines-v4'
 | 
			
		||||
export const META_STORE = 'meta-v4'
 | 
			
		||||
export const ACCOUNTS_STORE = 'accounts-v4'
 | 
			
		||||
export const RELATIONSHIPS_STORE = 'relationships-v4'
 | 
			
		||||
export const NOTIFICATIONS_STORE = 'notifications-v4'
 | 
			
		||||
export const NOTIFICATION_TIMELINES_STORE = 'notification_timelines-v4'
 | 
			
		||||
export const PINNED_STATUSES_STORE = 'pinned_statuses-v4'
 | 
			
		||||
export const THREADS_STORE = 'threads-v4'
 | 
			
		||||
 | 
			
		||||
export const TIMESTAMP = '__pinafore_ts'
 | 
			
		||||
export const ACCOUNT_ID = '__pinafore_acct_id'
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -18,7 +18,7 @@ import forEach from 'lodash/forEach'
 | 
			
		|||
const openReqs = {}
 | 
			
		||||
const databaseCache = {}
 | 
			
		||||
 | 
			
		||||
const DB_VERSION = 8
 | 
			
		||||
const DB_VERSION = 9
 | 
			
		||||
 | 
			
		||||
export function getDatabase (instanceName) {
 | 
			
		||||
  if (!instanceName) {
 | 
			
		||||
| 
						 | 
				
			
			@ -49,7 +49,7 @@ export function getDatabase (instanceName) {
 | 
			
		|||
        }
 | 
			
		||||
      }
 | 
			
		||||
 | 
			
		||||
      if (e.oldVersion < 7) {
 | 
			
		||||
      if (e.oldVersion < DB_VERSION) {
 | 
			
		||||
        createObjectStore(STATUSES_STORE, {keyPath: 'id'}, {
 | 
			
		||||
          [TIMESTAMP]: TIMESTAMP,
 | 
			
		||||
          [REBLOG_ID]: REBLOG_ID
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Ładowanie…
	
		Reference in New Issue