Skip to content

Commit 595028e

Browse files
authored
make RequestContext serializable (#578)
1 parent 181c5d9 commit 595028e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lambda-http/src/request.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ use aws_lambda_events::apigw::{ApiGatewayWebsocketProxyRequest, ApiGatewayWebsoc
1717
use aws_lambda_events::{encodings::Body, query_map::QueryMap};
1818
use http::header::HeaderName;
1919
use http::{HeaderMap, HeaderValue};
20-
use serde::Deserialize;
20+
use serde::{Deserialize, Serialize};
2121
use serde_json::error::Error as JsonError;
2222
use std::future::Future;
2323
use std::pin::Pin;
@@ -330,7 +330,7 @@ fn apigw_path_with_stage(stage: &Option<String>, path: &str) -> String {
330330

331331
/// Event request context as an enumeration of request contexts
332332
/// for both ALB and API Gateway and HTTP API events
333-
#[derive(Deserialize, Debug, Clone)]
333+
#[derive(Deserialize, Debug, Clone, Serialize)]
334334
#[serde(untagged)]
335335
pub enum RequestContext {
336336
/// API Gateway proxy request context

0 commit comments

Comments
 (0)