created testfunction and check_logged_in_users
fixed conflicts