moved method to resourceHandler, added tests