fixed todo error if pw not equal or username not set