fix errors in users controller