lib/name.js
function order(type, name) {
  if (type === '' || type === 'M') return name;
  if (type === 'm') return type + name;
  if (type === 'aug') return name + '#5';
  if (type === 'm#5') return 'm' + name + '#5';
  if (type === 'dim') return name === 'b7' ? 'dim7' : 'm' + name + 'b5';
  if (type === 'Mb5') return name + 'b5';
  else return name + type;
}
function order(type, name) {
  if (type === '' || type === 'M') return name;
  if (type === 'm') return type + name;
  if (type === 'aug') return name + '#5';
  if (type === 'm#5') return 'm' + name + '#5';
  if (type === 'dim') return name === 'b7' ? 'dim7' : 'm' + name + 'b5';
  if (type === 'Mb5') return name + 'b5';
  else return name + type;
}
function order ( type , name ) { if ( type === '' || type === 'M' ) return name ; if ( type === 'm' ) return type + name ; if ( type === 'aug' ) return name + '#5' ; if ( type === 'm#5' ) return 'm' + name + '#5' ; if ( type === 'dim' ) return name === 'b7' ? 'dim7' : 'm' + name + 'b5' ; if ( type === 'Mb5' ) return name + 'b5' ; else return name + type ; }
Return chord type and extensions in the correct order
Return chord type and extensions in the correct order