fixed bug in creating users