Skip to content

Commit

Permalink
Improve error message for non-file URLs
Browse files Browse the repository at this point in the history
Summary: Include the actual scheme instead of "non-file".

Reviewed By: javache

Differential Revision: D3555812

fbshipit-source-id: 3ae0490f2d8fae01a551ba2877789dc15818fc50
  • Loading branch information
adamjernst authored and Facebook Github Bot 2 committed Jul 13, 2016
1 parent 90c2605 commit 37d0339
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion React/Base/RCTJavaScriptLoader.m
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,8 @@ + (NSData *)attemptSynchronousLoadOfBundleAtURL:(NSURL *)scriptURL
*error = [NSError errorWithDomain:RCTJavaScriptLoaderErrorDomain
code:RCTJavaScriptLoaderErrorCannotBeLoadedSynchronously
userInfo:@{NSLocalizedDescriptionKey:
@"Cannot load non-file URLs synchronously"}];
[NSString stringWithFormat:@"Cannot load %@ URLs synchronously",
scriptURL.scheme]}];
}
return nil;
}
Expand Down

0 comments on commit 37d0339

Please sign in to comment.