     
     //#pragma mark -
     
-    public init(url: NSURL) {
+    public init(url: URL) {
         self.url = url
-        self.docURL = url.URLByAppendingPathComponent(cStringFileFolder)
+        self.docURL = url.appendingPathComponent(cStringFileFolder)
         setupFileStores()
     }
 

        return result;
    }
    
    public func update(inout aNode: Node) {
        if aNode.dirty {
            nodeStore.updateValue(aNode)
            

        //var error : NSError?
        
        // TODO: ERROR Handling
        let directoryFileWrapper: FileWrapper? = try! FileWrapper(url: url, options:FileWrapper.ReadingOptions.immediate)
        
        if directoryFileWrapper == nil {
            // file wrapper does not exist yet
            let fileManager = FileManager.default
            
            //error = nil;  // remove file not found error
            
            try! fileManager.createDirectory(at: url, withIntermediateDirectories: true, attributes: nil)
            
            try! fileManager.createDirectory(at: docURL, withIntermediateDirectories: true, attributes: nil)
            
        } else {
            if !directoryFileWrapper!.isDirectory {
                // if filewrapper not a folder -> ERROR
                // TODO : set error
                //self.error = NSError(domain: "graphdb.sobj.com", code: 1, userInfo: nil)
