minimum login/register function works