Fix notice in SearchPlugin::handle()

There can be dirs in that list that have no extension defined.