abstrated out PrePatcher
Merge pull request #1054 from AbrarSyed/master

abstrated out PrePatcher