UI: Delete cookies on profile removal

This commit is contained in:
jp9000 2019-02-13 19:39:55 -08:00
parent e67d04270a
commit 7edbb2f149
2 changed files with 11 additions and 0 deletions

View file

@ -88,6 +88,15 @@ void DestroyPanelCookieManager()
#endif
}
void DeleteCookies()
{
#ifdef BROWSER_AVAILABLE
if (panel_cookies) {
panel_cookies->DeleteCookies("", "");
}
#endif
}
void DuplicateCurrentCookieProfile(ConfigFile &config)
{
#ifdef BROWSER_AVAILABLE

View file

@ -28,6 +28,7 @@
extern void DestroyPanelCookieManager();
extern void DuplicateCurrentCookieProfile(ConfigFile &config);
extern void CheckExistingCookieId();
extern void DeleteCookies();
void EnumProfiles(std::function<bool (const char *, const char *)> &&cb)
{
@ -461,6 +462,7 @@ void OBSBasic::on_actionRemoveProfile_triggered()
Auth::Save();
auth.reset();
DeleteCookies();
DestroyPanelCookieManager();
config.Swap(basicConfig);