MCPcopy Create free account
hub / github.com/NativeScript/SimDeck / extra_allowed_origins

Function extra_allowed_origins

packages/server/src/auth.rs:274–286  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

272}
273
274fn extra_allowed_origins() -> impl Iterator<Item = String> {
275 std::env::var("SIMDECK_ALLOWED_ORIGINS")
276 .ok()
277 .into_iter()
278 .flat_map(|value| {
279 value
280 .split(',')
281 .map(str::trim)
282 .filter(|value| !value.is_empty())
283 .map(ToOwned::to_owned)
284 .collect::<Vec<_>>()
285 })
286}
287
288fn chrono_free_now_nanos() -> u128 {
289 std::time::SystemTime::now()

Callers 1

origin_is_allowedFunction · 0.85

Calls 1

is_emptyMethod · 0.80

Tested by

no test coverage detected