bugs in init func
bugs in init func