Refactor after new specs have been merged to master