Auth subsystem update
This commit is contained in:
parent
3e9f424c92
commit
2293c377eb
2 changed files with 4 additions and 4 deletions
|
|
@ -1,8 +1,8 @@
|
|||
#include "auth_system.h"
|
||||
|
||||
|
||||
const user_entity& auth_system::get_user(const QString &login, bool &success) {
|
||||
user_entity *out;
|
||||
const user_entity* auth_system::get_user(const QString &login, bool &success) {
|
||||
user_entity *out = nullptr;
|
||||
|
||||
success = false;
|
||||
for (user_entity &item : this->_users) {
|
||||
|
|
@ -13,7 +13,7 @@ const user_entity& auth_system::get_user(const QString &login, bool &success) {
|
|||
}
|
||||
}
|
||||
|
||||
return *out;
|
||||
return out;
|
||||
}
|
||||
|
||||
bool auth_system::remove_user(const QString &login) {
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ private:
|
|||
public:
|
||||
auth_system() = default;
|
||||
|
||||
const user_entity& get_user(const QString &login, bool &success);
|
||||
const user_entity* get_user(const QString &login, bool &success);
|
||||
bool remove_user(const QString &login);
|
||||
bool register_user(const QString &login, const QString &password, UserRole role);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue