File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
model/src/log_sinks/types Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -106,7 +106,7 @@ pub async fn regenerate_webhook_secret(
106106 let config = WebhookConfig {
107107 url : existing_webhook_sink. url ,
108108 format : existing_webhook_sink. format ,
109- hmac_secret : Some ( hmac_secret ) ,
109+ hmac_secret,
110110 } ;
111111 st. application
112112 . add_log_sink ( SinkConfig :: Webhook ( config) )
@@ -136,7 +136,7 @@ pub async fn add_webhook_sink(
136136
137137 let hmac_secret = match existing_webhook_sink {
138138 Some ( SinkConfig :: Webhook ( WebhookConfig {
139- hmac_secret : Some ( existing_secret) ,
139+ hmac_secret : existing_secret,
140140 ..
141141 } ) ) => existing_secret,
142142 _ => generate_webhook_hmac_secret ( st. application . runtime ( ) ) ,
@@ -152,7 +152,7 @@ pub async fn add_webhook_sink(
152152 let config = WebhookConfig {
153153 url,
154154 format : args. format ,
155- hmac_secret : Some ( hmac_secret ) ,
155+ hmac_secret,
156156 } ;
157157 st. application
158158 . add_log_sink ( SinkConfig :: Webhook ( config) )
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ pub struct WebhookConfig {
1515 ) ]
1616 pub url : reqwest:: Url ,
1717 pub format : WebhookFormat ,
18- pub hmac_secret : Option < String > ,
18+ pub hmac_secret : String ,
1919}
2020
2121#[ cfg_attr( any( test, feature = "testing" ) , derive( proptest_derive:: Arbitrary ) ) ]
@@ -31,7 +31,7 @@ pub enum WebhookFormat {
3131pub struct SerializedWebhookConfig {
3232 pub url : String ,
3333 pub format : WebhookFormat ,
34- pub hmac_secret : Option < String > ,
34+ pub hmac_secret : String ,
3535}
3636
3737impl From < WebhookConfig > for SerializedWebhookConfig {
You can’t perform that action at this time.
0 commit comments