summaryrefslogtreecommitdiff
path: root/src/wasp-user-stats.el
diff options
context:
space:
mode:
authorLLLL Colonq <llll@colonq>2025-05-01 17:06:41 -0400
committerLLLL Colonq <llll@colonq>2025-05-01 17:06:41 -0400
commitfb01362a9dd816fc0d0e50052ab4764dd30e46f3 (patch)
treed581df21e161a0483d8b02ea4519debb4501a4a7 /src/wasp-user-stats.el
parentb21ecce6645fc17c520b722de3d96e550c77c490 (diff)
You know we love updating with a horrendous commit message
Diffstat (limited to 'src/wasp-user-stats.el')
-rw-r--r--src/wasp-user-stats.el13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/wasp-user-stats.el b/src/wasp-user-stats.el
index 19d297a4..285754f8 100644
--- a/src/wasp-user-stats.el
+++ b/src/wasp-user-stats.el
@@ -2,6 +2,11 @@
;;; Commentary:
;;; Code:
+(require 'dash)
+(require 's)
+(require 'ht)
+(require 'wasp-user)
+
(defvar w/user-faction-exemptions
(list
"LCOLONQ"
@@ -54,7 +59,15 @@
(w/user-faction-total 'tony)
(w/user-faction-total 'lever)))
+(defun w/user-ensure-name ()
+ "Ensure that the current user has a name assigned."
+ (let ((cur (alist-get :name w/user-current)))
+ (unless cur
+ (setf (alist-get :name w/user-current) w/user-current-name))))
+
(defun w/user-stats-update ()
+ "Ensure that the current user has all stats."
+ (w/user-ensure-name)
(w/user-ensure-faction)
(w/user-ensure-element))