Fixed some litte bug in auth and created new row function