update weird looking if statement