Browse Source

Revert PR test

rules-rpn
Xose Pérez 5 years ago
parent
commit
d765397bd9
2 changed files with 2 additions and 4 deletions
  1. +1
    -1
      code/espurna/config/general.h
  2. +1
    -3
      code/espurna/ws.ino

+ 1
- 1
code/espurna/config/general.h View File

@ -531,7 +531,7 @@
// there are no special requirements. Any static web server will do (NGinx, Apache, Lighttpd,...).
// The only requirement is that the resource must be available under this domain.
#ifndef WEB_REMOTE_DOMAIN
#define WEB_REMOTE_DOMAIN "*"
#define WEB_REMOTE_DOMAIN "http://espurna.io"
#endif
// -----------------------------------------------------------------------------


+ 1
- 3
code/espurna/ws.ino View File

@ -559,9 +559,7 @@ void wsSetup() {
// CORS
#ifdef WEB_REMOTE_DOMAIN
DefaultHeaders::Instance().addHeader("Access-Control-Allow-Origin", WEB_REMOTE_DOMAIN);
if (strcmp(WEB_REMOTE_DOMAIN, "*")) {
DefaultHeaders::Instance().addHeader("Access-Control-Allow-Credentials", "true");
}
DefaultHeaders::Instance().addHeader("Access-Control-Allow-Credentials", "true");
#endif
webServer()->on("/auth", HTTP_GET, _onAuth);


Loading…
Cancel
Save