Skip to content
This repository has been archived by the owner on Jun 23, 2019. It is now read-only.

Commit

Permalink
Make calendar to use UTC timezone instead of the user's current one.
Browse files Browse the repository at this point in the history
  • Loading branch information
soberman committed May 8, 2018
1 parent 3dee761 commit cb9719f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>
6 changes: 5 additions & 1 deletion Koyomi/DateModel.swift
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,11 @@ final class DateModel: NSObject {
// MARK: - Private Methods -

private extension DateModel {
var calendar: Calendar { return Calendar.current }
var calendar: Calendar {
var utcCalendar = Calendar.current
utcCalendar.timeZone = TimeZone(abbreviation: "UTC")!
return utcCalendar
}

func setup() {
selectedDates = [:]
Expand Down

0 comments on commit cb9719f

Please sign in to comment.