aboutsummaryrefslogtreecommitdiff
path: root/node_modules/ext-list/index.js
blob: ebee2ceb8f51da80abba49701759bcfdf4dbb62b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
'use strict';
var mimeDb = require('mime-db');

module.exports = function () {
	var ret = {};

	Object.keys(mimeDb).forEach(function (x) {
		var val = mimeDb[x];

		if (val.extensions && val.extensions.length > 0) {
			val.extensions.forEach(function (y) {
				ret[y] = x;
			});
		}
	});

	return ret;
};