Fixed Create Bug

Found and fixed bug in the create function