#1120 - applying CS fixes as per @dantleech's review