Skip to content
This repository has been archived by the owner on Feb 19, 2020. It is now read-only.

Calling getResourceValue asynchronously #443

Merged

Conversation

bmourat
Copy link
Contributor

@bmourat bmourat commented Aug 1, 2017

No description provided.

@msftclas
Copy link

msftclas commented Aug 1, 2017

@bmourat,
Thanks for having already signed the Contribution License Agreement. Your agreement was validated by Microsoft. We will now review your pull request.
Thanks,
Microsoft Pull Request Bot

dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^{
NSError *getResourceError = nil;
NSNumber *appSupportDirExcludedValue;
if ([directoryURL getResourceValue:&appSupportDirExcludedValue forKey:NSURLIsExcludedFromBackupKey error:&getResourceError] && appSupportDirExcludedValue) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Either log NSError or just pass nil

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please log the error using log level error.

NSNumber *appSupportDirExcludedValue;
if ([directoryURL getResourceValue:&appSupportDirExcludedValue forKey:NSURLIsExcludedFromBackupKey error:&getResourceError] && appSupportDirExcludedValue) {
NSError *setResourceError = nil;
[directoryURL setResourceValue:@NO forKey:NSURLIsExcludedFromBackupKey error:&setResourceError];

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

@ElektrojungeAtWork ElektrojungeAtWork merged commit 377ecab into bitstadium:develop Aug 3, 2017
@bmourat bmourat deleted the fix/get-resource-value-async branch August 11, 2017 10:57
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants