More cleanup
This commit is contained in:
parent
271a45e2b0
commit
3cca33eac3
|
@ -263,7 +263,6 @@ export default Vue.extend({
|
||||||
|
|
||||||
const currentProfile = JSON.parse(JSON.stringify(this.profileList[this.activeProfile]))
|
const currentProfile = JSON.parse(JSON.stringify(this.profileList[this.activeProfile]))
|
||||||
const primaryProfile = JSON.parse(JSON.stringify(this.profileList[0]))
|
const primaryProfile = JSON.parse(JSON.stringify(this.profileList[0]))
|
||||||
console.log("PRIMARY PROFILE:", primaryProfile)
|
|
||||||
|
|
||||||
if (this.isSubscribed) {
|
if (this.isSubscribed) {
|
||||||
currentProfile.subscriptions = currentProfile.subscriptions.filter((channel) => {
|
currentProfile.subscriptions = currentProfile.subscriptions.filter((channel) => {
|
||||||
|
|
|
@ -13,7 +13,6 @@ if (window && window.process && window.process.type === 'renderer') {
|
||||||
|
|
||||||
const remote = require('@electron/remote')
|
const remote = require('@electron/remote')
|
||||||
dbLocation = remote.app.getPath('userData')
|
dbLocation = remote.app.getPath('userData')
|
||||||
console.log("DB", dbLocation)
|
|
||||||
dbLocation = dbLocation + '/history.db'
|
dbLocation = dbLocation + '/history.db'
|
||||||
} else {
|
} else {
|
||||||
dbLocation = 'history.db'
|
dbLocation = 'history.db'
|
||||||
|
|
|
@ -54,7 +54,6 @@ const actions = {
|
||||||
} else {
|
} else {
|
||||||
// We want the primary profile to always be first
|
// We want the primary profile to always be first
|
||||||
// So sort with that then sort alphabetically by profile name
|
// So sort with that then sort alphabetically by profile name
|
||||||
console.log('PROFILE DB RESULTS', results)
|
|
||||||
const profiles = results.sort((a, b) => {
|
const profiles = results.sort((a, b) => {
|
||||||
if (a._id === 'allChannels') {
|
if (a._id === 'allChannels') {
|
||||||
return -1
|
return -1
|
||||||
|
@ -68,13 +67,10 @@ const actions = {
|
||||||
})
|
})
|
||||||
|
|
||||||
if (state.profileList.length < profiles.length) {
|
if (state.profileList.length < profiles.length) {
|
||||||
console.log("STATE LIST LESS RTHAN PROFILES LENGTH")
|
|
||||||
console.log(profiles, state.profileList)
|
console.log(profiles, state.profileList)
|
||||||
console.log("ROOTSTATE:SETTINGDEFATL", rootState.settings.defaultProfile)
|
|
||||||
const profileIndex = profiles.findIndex((profile) => {
|
const profileIndex = profiles.findIndex((profile) => {
|
||||||
return profile._id === rootState.settings.defaultProfile
|
return profile._id === rootState.settings.defaultProfile
|
||||||
})
|
})
|
||||||
console.log("INDEX", profileIndex)
|
|
||||||
if (profileIndex !== -1) {
|
if (profileIndex !== -1) {
|
||||||
dispatch('updateActiveProfile', profileIndex)
|
dispatch('updateActiveProfile', profileIndex)
|
||||||
}
|
}
|
||||||
|
|
|
@ -252,7 +252,6 @@ const actions = {
|
||||||
},
|
},
|
||||||
|
|
||||||
ytGetPlaylistInfo ({ rootState }, playlistId) {
|
ytGetPlaylistInfo ({ rootState }, playlistId) {
|
||||||
console.log("PALYLIST INTOFOF")
|
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
console.log(playlistId)
|
console.log(playlistId)
|
||||||
console.log('Getting playlist info please wait...')
|
console.log('Getting playlist info please wait...')
|
||||||
|
@ -298,7 +297,6 @@ const actions = {
|
||||||
limit: 'Infinity',
|
limit: 'Infinity',
|
||||||
requestOptions: { agent }
|
requestOptions: { agent }
|
||||||
}).then((result) => {
|
}).then((result) => {
|
||||||
console.log("RESULT PLAYLIST", result)
|
|
||||||
resolve(result)
|
resolve(result)
|
||||||
}).catch((err) => {
|
}).catch((err) => {
|
||||||
reject(err)
|
reject(err)
|
||||||
|
|
Loading…
Reference in New Issue