added compatibility with hapi 6