Skip to content

Commit 079fa02

Browse files
author
Premkumar Bhaskal
committed
fix returning empty value for empty header
get_http_request_headers_bytes return empty vec for empty header value but get_http_request_header_bytes returns None for empty header value. this commit intends to fix this inconsistency.
1 parent c8b2335 commit 079fa02

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/hostcalls.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ pub fn get_map_value_bytes(map_type: MapType, key: &str) -> Result<Option<Bytes>
269269
return_size,
270270
)))
271271
} else {
272-
Ok(None)
272+
Ok(Some(Vec::new()))
273273
}
274274
}
275275
Status::NotFound => Ok(None),

0 commit comments

Comments
 (0)