1. Sebastian Sdorra
  2. scm-manager

Commits

Sebastian Sdorra  committed 3c6b5a2

use status code 412 for failed plugin conditions

  • Participants
  • Parent commits 92aa64e
  • Branches default

Comments (0)

Files changed (1)

File scm-webapp/src/main/java/sonia/scm/api/rest/resources/PluginResource.java

View file
  • Ignore whitespace
    * <br />
    * <ul>
    *   <li>200 success</li>
-   *   <li>412 conflict</li>
+   *   <li>412 precondition failed</li>
    *   <li>500 internal server error</li>
    * </ul>
    *
     {
       logger.warn(
         "could not install plugin package, because the condition failed", ex);
-      response = Response.status(Status.CONFLICT).entity(
+      response = Response.status(Status.PRECONDITION_FAILED).entity(
         new RestActionResult(false)).build();
     }
     catch (Exception ex)
    * <br />
    * <ul>
    *   <li>200 success</li>
-   *   <li>412 conflict</li>
+   *   <li>412 precondition failed</li>
    *   <li>500 internal server error</li>
    * </ul>
    *