     func applicationDidEnterBackground(_ application: UIApplication) {
         // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
         // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
+        
         let dateFormatter = DateFormatter()
-        dateFormatter.dateFormat = "yyyy-MM-dd HH:mm:ss xx"
+        dateFormatter.dateFormat = "yyyy-MM-dd HH:mm:ss +zzzz"
         dateFormatter.calendar = Calendar(identifier: .iso8601)
         dateFormatter.locale = Locale(identifier: "en_US_POSIX")
         let stringDate = dateFormatter.string(from: Date())
         
         defaults.set(stringDate, forKey: "lastQuitDate")
         print(defaults.string(forKey: "lastQuitDate")!)
-        print("Application Entered Background")
     }
 
     func applicationWillEnterForeground(_ application: UIApplication) {

        shiftVolumeArray()
        
        let dateFormatter = DateFormatter()
        dateFormatter.dateFormat = "yyyy-MM-dd HH:mm:ss xx"
        dateFormatter.calendar = Calendar(identifier: .iso8601)
        dateFormatter.locale = Locale(identifier: "en_US_POSIX")
        let stringDate = dateFormatter.string(from: Date())

//
//  Created by Shao Qian MAH on 11/11/2016.
//  Copyright © 2016 HydroPal. All rights reserved.
// hello

import Foundation
import UIKit
