         self.username = username
     }
 
-    required init(coder aDecoder: NSCoder) {
+    public required init(coder aDecoder: NSCoder) {
         if let username = aDecoder.decodeObjectForKey("username") as? String,
             let id = aDecoder.decodeObjectForKey("id") as? String {
                 self.id = id

        }
    }

    func encodeWithCoder(aCoder: NSCoder) {
        aCoder.encodeObject(self.id, forKey: "id")
        aCoder.encodeObject(self.username, forKey: "username")
        if let authToken = self.authToken {

import Foundation
import KeychainAccess

public class User: NSObject, NSCoding {

    public let id: String
    let username: String
    var password: String?

