Skip to content

Commit

Permalink
fix(JavaScriptBundleLoader): PCLStorage does not work for this
Browse files Browse the repository at this point in the history
Apparently PCLStorage fails to resolve the ms-appx:/// URIs.  So, let's not use that.

cc @matthargett
  • Loading branch information
rozele committed Nov 1, 2016
1 parent 7c88e83 commit ddf0de8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using PCLStorage;
using System;
using System.Threading.Tasks;
using Windows.Storage;
#if !WINDOWS_UWP
using System.IO;
using System.Reflection;
Expand Down Expand Up @@ -91,7 +92,7 @@ public override async Task InitializeAsync()
try
{
#if WINDOWS_UWP
var storageFile = await FileSystem.Current.GetFileFromPathAsync(new Uri(SourceUrl).ToString()).ConfigureAwait(false);
var storageFile = await StorageFile.GetFileFromApplicationUriAsync(new Uri(SourceUrl));
_script = storageFile.Path;
#else
var assembly = Assembly.GetAssembly(typeof(JavaScriptBundleLoader));
Expand Down
2 changes: 2 additions & 0 deletions ReactWindows/ReactNative.Shared/CoreModulesPackage.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@
using ReactNative.UIManager.Events;
using System;
using System.Collections.Generic;
#if !WINDOWS_UWP
using System.Windows;
#endif

namespace ReactNative
{
Expand Down

0 comments on commit ddf0de8

Please sign in to comment.