 		}
 	}
 	
-	public func useOnQueue(queue: dispatch_queue_t, closure: (directoryURL: NSURL) -> Void) {
+	public func useOnQueue(queue: dispatch_queue_t, closure: (directoryURL: NSURL) -> ()) {
 		dispatch_group_notify(group, queue) {
 			if let createdDirectoryURL = self.createdDirectoryURL {
 				closure(directoryURL: createdDirectoryURL)

		createDirectory()
	}
	
	private func directoryURLResolver(fm fm: NSFileManager) throws -> NSURL? {
		return try fm.URLForDirectory(directoryBase, inDomain:.UserDomainMask, appropriateForURL:nil, create:true)
	}
	
	private func createDirectory() {
		let queue = dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_LOW, 0)
		dispatch_group_async(group, queue) {
			let fm = NSFileManager.defaultManager()
			
			do {
				guard let baseDirectoryURL = try self.directoryURLResolver(fm: fm) else { return }
				
				// Convert path to its components, so we can add more components
				// and convert back into a URL.

	public typealias ErrorReceiver = (NSError) -> ()
	
	public let pathComponents: [String]
	public let domainMask: NSSearchPathDomainMask
	public let directoryBase: NSSearchPathDirectory
	public let errorReceiver: ErrorReceiver
	private let group: dispatch_group_t
	private var createdDirectoryURL: NSURL?
	
	public init(pathComponents: [String], inUserDirectory directoryBase: NSSearchPathDirectory, errorReceiver: ErrorReceiver, useBundleIdentifier: Bool = true) {
		var pathComponents = pathComponents
		if useBundleIdentifier {
			if let bundleIdentifier = NSBundle.mainBundle().bundleIdentifier {
				pathComponents.insert(bundleIdentifier, atIndex: 0)
