Skip to content

Commit ece5ca9

Browse files
authored
fixes #540 payload_format default to empty (#541)
Signed-off-by: flbla <flbla@users.noreply.github.com>
1 parent e5f1390 commit ece5ca9

File tree

3 files changed

+2
-3
lines changed

3 files changed

+2
-3
lines changed

docs/resources/project_webhook.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ resource "harbor_project_webhook" "main" {
6666
- `description` (String) A description of the webhook.
6767
- `enabled` (Boolean) To enable / disable the webhook. Default `true`.
6868
- `skip_cert_verify` (Boolean) checks the for validate SSL certificate.
69-
- `payload_format` (String) Payload format sent by the webhook. Values are `Default` or `CloudEvents`. Default to `Default`.
69+
- `payload_format` (String) Payload format sent by the webhook. Values are `Default` or `CloudEvents`.
7070

7171
### Read-Only
7272

models/project_webhooks.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,5 @@ type WebHookTargets struct {
1919
AuthHeader string `json:"auth_header"`
2020
SkipCertVerify bool `json:"skip_cert_verify"`
2121
Address string `json:"address"`
22-
PayloadFormat string `json:"payload_format"`
22+
PayloadFormat string `json:"payload_format:omitempty"`
2323
}

provider/resource_harbor_project_webhook.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ func resourceProjectWebhook() *schema.Resource {
5959
"payload_format": {
6060
Type: schema.TypeString,
6161
Optional: true,
62-
Default: "Default",
6362
},
6463
},
6564
Create: resourceProjectWebhookCreate,

0 commit comments

Comments
 (0)