diff --git a/.drone.yml b/.drone.yml index 19921cd60..b59b6e9c4 100644 --- a/.drone.yml +++ b/.drone.yml @@ -40,10 +40,19 @@ pipeline: slack: image: plugins/slack - secrets: [ slack_webhook ] template: > {{#success build.status}} build {{build.number}} succeeded. Good job. {{else}} build {{build.number}} failed. Fix me please. - {{/success}} \ No newline at end of file + {{/success}} + secrets: [ slack_webhook ] + when: + status: [ failure, success ] + + cleanup: + commands: + - docker system prune -f + when: + status: failure + \ No newline at end of file diff --git a/src/Squidex.Infrastructure/TypeNameRegistry.cs b/src/Squidex.Infrastructure/TypeNameRegistry.cs index 77d4b5edf..b08259a04 100644 --- a/src/Squidex.Infrastructure/TypeNameRegistry.cs +++ b/src/Squidex.Infrastructure/TypeNameRegistry.cs @@ -78,7 +78,7 @@ namespace Squidex.Infrastructure { var typeNameAttribute = type.GetTypeInfo().GetCustomAttribute(); - if (typeNameAttribute != null && !string.IsNullOrWhiteSpace(typeNameAttribute.TypeName)) + if (!string.IsNullOrWhiteSpace(typeNameAttribute?.TypeName)) { Map(type, typeNameAttribute.TypeName); }