Rename SEARCH_PHASE to PHASE and SEARCH_CONTEXT to CONTEXT.
Inverse conditions.