File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed
src/Umbraco.Deploy.Contrib/Migrators/Legacy/DataType Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change
1
+ using System . Linq ;
1
2
using Newtonsoft . Json . Linq ;
2
3
using Semver ;
3
4
using Umbraco . Core ;
@@ -30,10 +31,17 @@ public override JToken Migrate(JToken artifactJson)
30
31
31
32
// Convert pre-value serialized JSON to actual JSON objects/arrays
32
33
if ( propertyValue . Type == JTokenType . String &&
33
- propertyValue . Value < string > ( ) is string json &&
34
- json . DetectIsJson ( ) )
34
+ propertyValue . Value < string > ( ) is string value )
35
35
{
36
- propertyValue = JToken . Parse ( json ) ;
36
+ if ( string . IsNullOrEmpty ( value ) )
37
+ {
38
+ // Skip empty value
39
+ continue ;
40
+ }
41
+ else if ( value . DetectIsJson ( ) )
42
+ {
43
+ propertyValue = JToken . Parse ( value ) ;
44
+ }
37
45
}
38
46
39
47
configuration . Add ( property . Name , propertyValue ) ;
You can’t perform that action at this time.
0 commit comments