AB3653 - Static IOHelper -> IIOHelper (Moved into Current as a first step 😭)
This commit is contained in:
@@ -9,6 +9,7 @@ using System.Xml.Linq;
|
||||
using ClientDependency.Core.CompositeFiles.Providers;
|
||||
using ClientDependency.Core.Config;
|
||||
using Semver;
|
||||
using Umbraco.Core.Composing;
|
||||
using Umbraco.Core.IO;
|
||||
using Umbraco.Core.Logging;
|
||||
|
||||
@@ -26,9 +27,9 @@ namespace Umbraco.Web.JavaScript
|
||||
{
|
||||
if (logger == null) throw new ArgumentNullException("logger");
|
||||
_logger = logger;
|
||||
_fileName = IOHelper.MapPath(string.Format("{0}/ClientDependency.config", SystemDirectories.Config));
|
||||
_fileName = Current.IOHelper.MapPath(string.Format("{0}/ClientDependency.config", SystemDirectories.Config));
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Changes the version number in ClientDependency.config to a hashed value for the version and the DateTime.Day
|
||||
/// </summary>
|
||||
@@ -39,7 +40,7 @@ namespace Umbraco.Web.JavaScript
|
||||
public bool UpdateVersionNumber(SemVersion version, DateTime date, string dateFormat)
|
||||
{
|
||||
var byteContents = Encoding.Unicode.GetBytes(version + date.ToString(dateFormat));
|
||||
|
||||
|
||||
//This is a way to convert a string to a long
|
||||
//see https://www.codeproject.com/Articles/34309/Convert-String-to-bit-Integer
|
||||
//We could much more easily use MD5 which would create us an INT but since that is not compliant with
|
||||
@@ -106,7 +107,7 @@ namespace Umbraco.Web.JavaScript
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
{
|
||||
var fullPath = XmlFileMapper.FileMapDefaultFolder.StartsWith("~/")
|
||||
? currentHttpContext.Server.MapPath(XmlFileMapper.FileMapDefaultFolder)
|
||||
: XmlFileMapper.FileMapDefaultFolder;
|
||||
|
||||
@@ -6,6 +6,7 @@ using System.Web;
|
||||
using ClientDependency.Core;
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using Umbraco.Core.Composing;
|
||||
using Umbraco.Core.IO;
|
||||
using Umbraco.Core.Manifest;
|
||||
|
||||
@@ -57,7 +58,7 @@ namespace Umbraco.Web.JavaScript
|
||||
}
|
||||
jarray.Append("]");
|
||||
|
||||
return WriteScript(jarray.ToString(), IOHelper.ResolveUrl(SystemDirectories.Umbraco), angularModule);
|
||||
return WriteScript(jarray.ToString(), Current.IOHelper.ResolveUrl(SystemDirectories.Umbraco), angularModule);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
using System.Web.UI;
|
||||
using ClientDependency.Core.Controls;
|
||||
using ClientDependency.Core.FileRegistration.Providers;
|
||||
using Umbraco.Core.Composing;
|
||||
using Umbraco.Core.IO;
|
||||
|
||||
namespace Umbraco.Web.JavaScript
|
||||
@@ -17,7 +18,7 @@ namespace Umbraco.Web.JavaScript
|
||||
public UmbracoClientDependencyLoader()
|
||||
: base()
|
||||
{
|
||||
this.AddPath("UmbracoRoot", IOHelper.ResolveUrl(SystemDirectories.Umbraco));
|
||||
this.AddPath("UmbracoRoot", Current.IOHelper.ResolveUrl(SystemDirectories.Umbraco));
|
||||
this.ProviderName = LoaderControlProvider.DefaultName;
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user