Revert "Fixes: U4-4211 User without media section permission will be logged out immediately when accessing a document type using a media picker datatype (u7.0.3) - this is done by using the entityResource in the mediaPicker but to do this we need to return a cut down version of the media properties in the additionalData which is tricky because the cropper stores json which is ntext and the existing sql didn't cater for this. This also cleans up the entity service and we no longer have this internal collection of properties, everything is just added to additionalData, then had to add mediaHelper method to deal with getting urls from a media 'entity' not just a media object."
This reverts commit c38c2ede11.
This commit is contained in:
@@ -10,7 +10,6 @@ using System.Text;
|
||||
using System.Text.RegularExpressions;
|
||||
using System.Web;
|
||||
using System.Xml;
|
||||
using Newtonsoft.Json;
|
||||
using Umbraco.Core.Configuration;
|
||||
using System.Web.Security;
|
||||
using Umbraco.Core.Strings;
|
||||
@@ -53,28 +52,6 @@ namespace Umbraco.Core
|
||||
|| (input.StartsWith("[") && input.EndsWith("]"));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns a JObject/JArray instance if the string can be converted to json, otherwise returns the string
|
||||
/// </summary>
|
||||
/// <param name="input"></param>
|
||||
/// <returns></returns>
|
||||
internal static object ConvertToJsonIfPossible(this string input)
|
||||
{
|
||||
if (input.DetectIsJson() == false)
|
||||
{
|
||||
return input;
|
||||
}
|
||||
try
|
||||
{
|
||||
var obj = JsonConvert.DeserializeObject(input);
|
||||
return obj;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return input;
|
||||
}
|
||||
}
|
||||
|
||||
internal static string ReplaceNonAlphanumericChars(this string input, char replacement)
|
||||
{
|
||||
//any character that is not alphanumeric, convert to a hyphen
|
||||
|
||||
Reference in New Issue
Block a user