MOBILE-4065 dev: Reset site onboarding when reseting tours

main
Pau Ferrer Ocaña 2023-02-13 12:28:10 +01:00
parent f84a0c659a
commit 0b9b617fa8
1 changed files with 5 additions and 0 deletions

View File

@ -13,8 +13,10 @@
// limitations under the License.
import { Component, OnInit } from '@angular/core';
import { CoreLoginHelperProvider } from '@features/login/services/login-helper';
import { CoreSitePlugins } from '@features/siteplugins/services/siteplugins';
import { CoreUserTours } from '@features/usertours/services/user-tours';
import { CoreConfig } from '@services/config';
import { CorePlatform } from '@services/platform';
import { CoreSites } from '@services/sites';
import { CoreDomUtils } from '@services/utils/dom';
@ -149,6 +151,9 @@ export class CoreSettingsDevPage implements OnInit {
*/
async resetUserTours(): Promise<void> {
await CoreUserTours.resetTours();
await CoreConfig.delete(CoreLoginHelperProvider.ONBOARDING_DONE);
CoreDomUtils.showToast('User tours have been reseted');
}