#include "stg/auth.h"
#include "stg/store.h"
#include "stg/module_settings.h"
-#include "stg/notifer.h"
#include "stg/user_ips.h"
#include "stg/user.h"
#include "stg/users.h"
class AUTH_IA;
using UserPtr = STG::User*;
//-----------------------------------------------------------------------------
-class DEL_USER_NOTIFIER: public STG::NotifierBase<UserPtr> {
-public:
- explicit DEL_USER_NOTIFIER(AUTH_IA & a) : auth(a) {}
- virtual ~DEL_USER_NOTIFIER() {}
-
- void Notify(const UserPtr & user);
-private:
- DEL_USER_NOTIFIER(const DEL_USER_NOTIFIER & rvalue);
- DEL_USER_NOTIFIER & operator=(const DEL_USER_NOTIFIER & rvalue);
-
- AUTH_IA & auth;
-};
-//-----------------------------------------------------------------------------
class AUTH_IA : public STG::Auth {
-friend class DEL_USER_NOTIFIER;
public:
AUTH_IA();
~AUTH_IA() override;
uint32_t enabledDirs;
- DEL_USER_NOTIFIER onDelUserNotifier;
+ STG::ScopedConnection m_onDelUserConn;
STG::PluginLogger logger;
AUTH_IA * auth;
};
-//-----------------------------------------------------------------------------
-inline
-void DEL_USER_NOTIFIER::Notify(const UserPtr & user)
-{
- auth.DelUser(user);
-}