updating hooks to have context and post/pre done in correct env
Merge branch 'master' into dev

* master:
  updating hooks to have context and post/pre done in correct env