FedericoCeratto/bottle-cork — pull request #50 by nithinbose87 (2013-10-21 03:16:59+00:00)
Title: added the initialize param to create_user and create_role

This param allows us to ignore current user privileges and use the create_user and create_role functions when initializing the db.
For example:

mbInit = MongoDBBackend(
db_name=USERS_DB_NAME,
hostname=USERS_DB_HOST,
initialize=True)
aaaInit = Cork(backend=mbInit)
aaaInit.create_role('admin', '100', True)
aaaInit.create_role('user', '50', True)

aaaInit.create_user('admin', 'admin', 'admin', initialize=True)
aaaInit.create_user('user', 'user', 'user', initialize=True)