Condensed the plugin name fallback logic