summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornsensfel <SpamShield0@noot-noot.org>2018-12-13 19:09:49 +0100
committernsensfel <SpamShield0@noot-noot.org>2018-12-13 19:09:49 +0100
commit3ffb430c28ba3c04835d2762a17aac39a1e64ded (patch)
treee0200629f57ad717cb247a2cae71d266217848a7 /src/shared/struct
parentda06d32b135b3bc29cedd15ed8630a0eef0c2ab3 (diff)
...
Diffstat (limited to 'src/shared/struct')
-rw-r--r--src/shared/struct/shr_db_user.erl5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/shared/struct/shr_db_user.erl b/src/shared/struct/shr_db_user.erl
index 8368024..dcd8685 100644
--- a/src/shared/struct/shr_db_user.erl
+++ b/src/shared/struct/shr_db_user.erl
@@ -15,7 +15,7 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-export_type([user/0, permission/0]).
--export([can_access/2]).
+-export([can_access/2, player/1]).
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% LOCAL FUNCTIONS %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -24,6 +24,9 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% EXPORTED FUNCTIONS %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+-spec player (shr_player:id()) -> db_user().
+player (ID) -> {user, ID}.
+
-spec can_access (permission(), user()) -> boolean().
can_access (_, admin) -> true;
can_access (any, _) -> true;