Handle middleware prefix (main module name)