register the correct class for middleman