nested helper
allow overriding the root context