Browse Source

modify init-db func. in nera package.

This is part of a refactoring to allow the user to set more settings in the
initial set-up/first run process.
stable
Craig Oates 2 years ago
parent
commit
324229dea4
  1. 7
      src/nera.lisp

7
src/nera.lisp

@ -54,7 +54,8 @@
(defun init-db (request)
"Creates the database and creates Admin. in `USER' table."
(destructuring-bind
(&key username display-name password allow-sign-up &allow-other-keys)
(&key site-name allow-sign-up show-site-logo username display-name password
&allow-other-keys)
(utils:request-params request)
(with-connection (db)
;; Add to the list to add more tables.
@ -65,7 +66,9 @@
:password (hermetic::hash password)
:administrator +true+)
(mito:create-dao 'site-settings
:enable-sign-up (utils:checkbox-to-bool allow-sign-up))
:site-name site-name
:enable-sign-up (utils:checkbox-to-bool allow-sign-up)
:enable-site-logo (utils:checkbox-to-bool show-site-logo))
(mito:create-dao 'page
:title "Home"
:slug "home"

Loading…
Cancel
Save