added log_in functionality