'use strict';

function parseQueryParamAsArray(p) {
  return function parseQueryParameter(q) {
    var query = {};
    query[p] = q[p].split(',');

    return query;
  };
}

module.exports = parseQueryParamAsArray;

'use strict';

function parseQueryParamAsArray(p) {
  return function parseQueryParameter(q) {
    var query = {};
    query[p] = (q && q[p]) ? q[p].split(',') : [];

    return query;
  };
}

module.exports = parseQueryParamAsArray;

Fix array parser parsing blank string.
Fix array parser parsing blank string.
