remove unreachable if
refactor the plugin stage calling code.
Merge pull request #233 from meadsteve/build-status-fix

Refactor how the plugin stages are called