Change the way we match headers when finding a phase

The previous way was causing a stale element reference error because
the column was getting repainted after getting matched.

Also removes an unused method, and unneeded application error check.