Patch-up for new Map-based MIDI port lists

This enables the template to work for new-style MIDIAccess (on Canary) as well as old-style.