Well, that’s not entirely the case. It is more that Discord has blocked Worker’s IPs from connecting
Well, that’s not entirely the case. It is more that Discord has blocked Worker’s IPs from connecting to the Gateway
npm run dev and worker A is bound to worker B. Worker B calls Worker A, and when I start Worker B I get:Cannot read properties of undefined (reading 'fetch') wrangler tail overnight and hope for the bestwhile true; do wrangler tail; end ? npm run dev⛅️ wrangler 3.41.0
-------------------
▲ [WARNING] This worker is bound to live services: AUTH (authentication-worker)
Your worker has access to the following bindings:
- Services:
- AUTH: authentication-worker
▲ [WARNING] ⎔ Support for service bindings in local mode is experimental and may change.Cannot read properties of undefined (reading 'fetch')wrangler tailwhile true; do wrangler tail; end#[event(fetch)]
async fn fetch(req: HttpRequest, _env: Env, _ctx: Context) -> Result<Response<Body>> {
console_error_panic_hook::set_once();
let cors = CorsLayer::new()
.allow_origin("https://shorter.dev".parse::<HeaderValue>().unwrap())
.allow_headers([CONTENT_TYPE])
.allow_methods([Method::GET, Method::POST, Method::HEAD, Method::OPTIONS]);
let app = Router::new()
.route("/", get(|| async { "shorter.dev server!" }))
.merge(mount())
.layer(cors)
.call(req)
.await?;
Ok(app)
}