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

Call to formatDate has wrong parameters for usa format option #25

Open
ozzierod opened this issue May 21, 2012 · 1 comment
Open

Call to formatDate has wrong parameters for usa format option #25

ozzierod opened this issue May 21, 2012 · 1 comment

Comments

@ozzierod
Copy link

When including the option for usa date format, the date range seems to break on the end date. This is do to the fact that the plugin is calling formatDate on line 382 with the wrong parameters.

This:

                          if (endDate >= selected) {
                                options.endDate.val(formatDate(
                                    new Date(
                                        date.getTime() +
                                        endDate.getTime() -
                                        selected.getTime()
                                    ),
                                    options.usa,
                                    options.separator
                                ));
                            }

Should be:

                            if (endDate >= selected) {
                                options.endDate.val(formatDate(
                                    new Date(
                                        date.getTime() +
                                        endDate.getTime() -
                                        selected.getTime()
                                    ),
                                    options
                                ));
                            }
@dnd
Copy link
Contributor

dnd commented May 22, 2012

I have this fixed my fork, and submitted pull request #21, but so far the maintainer hasn't pulled in the changes.

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