- wrapObsFun
- <P, R, H1 extends ClientFilterHookName, H2 extends ClientFilterHookName>
- (fun: ObservableFunction<P, R>, params: P, scope: PluginClientScope, hookParamName: H1, hookResultName: H2) {
+ this.authService.loginChangedSource.subscribe(obj => {
+ if (obj === AuthStatus.LoggedIn) {
+ this.runAction('action:auth-user.logged-in', 'common')
+ } else if (obj === AuthStatus.LoggedOut) {
+ this.runAction('action:auth-user.logged-out', 'common')
+ }
+ })
+ }
+
+ wrapObsFun <P, R, H1 extends ClientFilterHookName, H2 extends ClientFilterHookName>
+ (fun: ObservableFunction<P, R>, params: P, scope: PluginClientScope, hookParamName: H1, hookResultName: H2) {