cleaned up user code