@@ -23,11 +23,53 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
2323 * // Push notification support (Optional)
2424 * [self registerForPushNotifications:application];
2525 */
26-
26+
27+ // Testing: Check our prefs. Remove later.
28+
29+ NSString * path =
30+ [NSSearchPathForDirectoriesInDomains (NSDocumentDirectory, NSUserDomainMask, YES )
31+ firstObject ];
32+
33+ NSError *error = nil ;
34+ NSArray *files =
35+ [[NSFileManager defaultManager ]
36+ contentsOfDirectoryAtPath: path
37+ error: &error];
38+ NSLog (@" Doc Files (error: %@ ):\n %@ " , error, files);
39+
2740 Branch *branch = [Branch getInstance ];
2841 [branch setDebug ];
2942 [branch setWhiteListedSchemes: @[@" branchtest" ]];
30-
43+
44+ // Testing: Check our prefs
45+
46+ files =
47+ [[NSFileManager defaultManager ]
48+ contentsOfDirectoryAtPath: path
49+ error: &error];
50+ NSLog (@" Doc Files (error: %@ ):\n %@ " , error, files);
51+
52+ NSURL *URL =
53+ [[NSFileManager defaultManager ]
54+ URLForDirectory: NSApplicationSupportDirectory
55+ inDomain: NSUserDomainMask
56+ appropriateForURL: nil
57+ create: YES
58+ error: &error];
59+ if (error) {
60+ NSLog (@" Error creating URLForPrefsDirectory: %@ ." , error);
61+ return nil ;
62+ }
63+ URL = [URL URLByAppendingPathComponent: @" io.branch" ];
64+
65+ files =
66+ [[NSFileManager defaultManager ]
67+ contentsOfDirectoryAtPath: URL.path
68+ error: &error];
69+ NSLog (@" App Files (error: %@ ):\n %@ " , error, files);
70+
71+ // Testing: End checks.
72+
3173 // Automatic Deeplinking on "deeplink_text"
3274 NavigationController *navigationController = [[UIStoryboard storyboardWithName: @" Main" bundle: [NSBundle mainBundle ]] instantiateInitialViewController ];
3375 [branch registerDeepLinkController: navigationController forKey: @" deeplink_text" ];
0 commit comments