Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Every minute past every hour #25

Open
dhwang opened this issue Oct 7, 2016 · 1 comment
Open

Every minute past every hour #25

dhwang opened this issue Oct 7, 2016 · 1 comment

Comments

@dhwang
Copy link

dhwang commented Oct 7, 2016

When cron expression specifies to run on every minutes, it currently enumerates every minutes from 0 to 59. It would be simpler to simply skip the enumeration in this case and just leave it at "Every minute past every hour".

var numberList = function(numbers, unit) {
    if (numbers.length < 2) {
      return moment()._locale.ordinal(numbers);
    }

   // skip enumeration
    if (unit && unit === 'm' && numbers.length == 60)
      return ' '; // "Every minute"

   var last_val = numbers.pop();
    return numbers.join(', ') + ' and ' + moment()._locale.ordinal(last_val);
  };
@dhwang dhwang changed the title Every minutes of every hour Every minute past every hour Oct 7, 2016
@anderssonjohan
Copy link
Collaborator

This should be fixed with changes made in #28

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants