Wrong expiration date shown on members page in project settings

Summary

Expires_at date shown on project_members page shows one day before actual expiration date.

Steps to reproduce

Either use Add member or Share with group to add a member or group, along with an expiration date some time in the future. After you submit the form, you should immediately see that the date displayed is one day before the previously set date.

Relevant logs and/or screenshots

Screen_Shot_2018-09-27_at_12.18.59_PM

Screen_Shot_2018-09-27_at_12.19.35_PM

Results of GitLab environment info

This happens on gitlab.com as well. I added @dstanley to the project with an expiration of 2018-10-31 and now it shows 2018-10-30.

Possible fixes

I believe it's an issue with the calendar picker. If I temporarily remove the 'js-access-expiration-date' from the view in /app/views/shared/members/_group.html.haml, thus disabling the date picker, then it displays the correct date.

Assignee Loading
Time tracking Loading