Skip to content

Commit

Permalink
Getting rid of some warnings
Browse files Browse the repository at this point in the history
Following a previous upgrade of Skybrud.Essentials, the JSON converters in the "Essentials.Json.Converters" namespace are now obsolete, and the JSON converters in the "Essentials.Json.Newtonsoft.Converters" namespace should be used instead.
  • Loading branch information
abjerner committed Nov 27, 2023
1 parent 07ec147 commit c6840ff
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 6 deletions.
4 changes: 0 additions & 4 deletions src/Skybrud.Umbraco.Redirects/Models/Dtos/RedirectDto.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
using System;
using Newtonsoft.Json;
using NPoco;
using Skybrud.Essentials.Json.Converters.Time;
using Skybrud.Umbraco.Redirects.Models.Schema;
using Umbraco.Cms.Infrastructure.Persistence.DatabaseAnnotations;

Expand Down Expand Up @@ -104,14 +102,12 @@ public class RedirectDto {
/// Gets or sets the timestamp for when the redirect was created.
/// </summary>
[Column("Created")]
[JsonConverter(typeof(TimeConverter))]
public DateTime Created { get; set; }

/// <summary>
/// Gets or sets the timestamp for when the redirect was last updated.
/// </summary>
[Column("Updated")]
[JsonConverter(typeof(TimeConverter))]
public DateTime Updated { get; set; }

/// <summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace Skybrud.Umbraco.Redirects.Models {
/// <summary>
/// Enum describing the type of the link.
/// </summary>
[NewtonsoftJsonConverter(typeof(Essentials.Json.Converters.Enums.EnumCamelCaseConverter))]
[NewtonsoftJsonConverter(typeof(Essentials.Json.Newtonsoft.Converters.Enums.EnumCamelCaseConverter))]
[MicrosoftJsonConverter(typeof(Text.Json.Enums.EnumCamelCaseConverter))]
public enum RedirectDestinationType {

Expand Down
2 changes: 1 addition & 1 deletion src/Skybrud.Umbraco.Redirects/Models/RedirectType.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace Skybrud.Umbraco.Redirects.Models {
/// <summary>
/// Enum class indicating the type of a redirect - eg. <see cref="Permanent"/> or <see cref="Temporary"/>.
/// </summary>
[NewtonsoftJsonConverter(typeof(Essentials.Json.Converters.Enums.EnumCamelCaseConverter))]
[NewtonsoftJsonConverter(typeof(Essentials.Json.Newtonsoft.Converters.Enums.EnumCamelCaseConverter))]
[MicrosoftJsonConverter(typeof(Text.Json.Enums.EnumCamelCaseConverter))]
public enum RedirectType {

Expand Down

0 comments on commit c6840ff

Please sign in to comment.