Added $override to substituteObjects for testing purposes