Commit 892f74fd authored by yalh76's avatar yalh76

fixes

parent aafa9f3b
......@@ -37,7 +37,7 @@ parser.add_argument('-u', '--usercreate',
dest="command",
help="created user",
action="store_const",
const="user")
const="usercreate")
parser.add_argument('--username', required=False, help="username")
......@@ -65,7 +65,7 @@ elif args.command == 'settings' and args.config:
elif args.command == 'db':
connect()
create_tables()
elif args.command == 'usercreate' and args.username:
elif args.command == 'usercreate':
create_user(args.username, args.password, args.email, args.is_admin)
elif args.command == 'travis':
travis_setup()
......
......@@ -5,7 +5,7 @@ from models.user import UserProfile
from managers.user_manager import new_user
from settings import salt_code
def create_user(username='config/docker.yaml', password='settings.py', email='settings.py', is_admin='settings.py'):
def create_user(username, password, email, is_admin=False):
new_user(
username = username,
......@@ -13,7 +13,7 @@ def create_user(username='config/docker.yaml', password='settings.py', email='se
email = email,
description= "",
confirmed=True,
is_admin = admin,
is_admin = is_admin,
is_remote=False,
is_private=False
)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment