mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-24 04:16:00 +08:00
Rely only on scriptURL when loading images
Reviewed By: @foghina Differential Revision: D2527119 fb-gh-sync-id: e2a9618f729a2ec03b1959fa13fae46620cc379e
This commit is contained in:
committed by
facebook-github-bot-9
parent
5e33dbcfcc
commit
62d0586e59
@@ -20,10 +20,6 @@ var SourceCode = require('NativeModules').SourceCode;
|
||||
var _serverURL;
|
||||
|
||||
function getDevServerURL() {
|
||||
if (!__DEV__) {
|
||||
// In prod we want assets to be loaded from the archive
|
||||
return null;
|
||||
}
|
||||
if (_serverURL === undefined) {
|
||||
var scriptURL = SourceCode.scriptURL;
|
||||
var match = scriptURL && scriptURL.match(/^https?:\/\/.*?\//);
|
||||
|
||||
Reference in New Issue
Block a user