mirror of
https://github.com/Eugeny/tabby.git
synced 2024-12-09 06:20:22 +08:00
ignore fewer errors in profileSettingsTab
This commit is contained in:
parent
176992a629
commit
2baede4675
@ -102,17 +102,20 @@ export class ProfilesSettingsTabComponent extends BaseComponent {
|
||||
}
|
||||
modal.componentInstance.profile = deepClone(profile)
|
||||
modal.componentInstance.profileProvider = provider
|
||||
try {
|
||||
const result = await modal.result
|
||||
// Fully replace the config
|
||||
for (const k in profile) {
|
||||
// eslint-disable-next-line @typescript-eslint/no-dynamic-delete
|
||||
delete profile[k]
|
||||
}
|
||||
Object.assign(profile, result)
|
||||
|
||||
profile.type = provider.id
|
||||
} catch (e) { }
|
||||
const result = await modal.result.catch(() => null)
|
||||
if (!result) {
|
||||
return
|
||||
}
|
||||
|
||||
// Fully replace the config
|
||||
for (const k in profile) {
|
||||
// eslint-disable-next-line @typescript-eslint/no-dynamic-delete
|
||||
delete profile[k]
|
||||
}
|
||||
Object.assign(profile, result)
|
||||
|
||||
profile.type = provider.id
|
||||
}
|
||||
|
||||
async deleteProfile (profile: PartialProfile<Profile>): Promise<void> {
|
||||
|
Loading…
Reference in New Issue
Block a user