Code Monkey home page Code Monkey logo

Comments (4)

gmag11 avatar gmag11 commented on July 26, 2024

This is caused by a change on AsyncWebServer library. I've updated my code to fix this on develop branch. Check #8
I've just updated master branch to implement this change

from fsbrowserng.

sekt1953 avatar sekt1953 commented on July 26, 2024

You fix is working on Arduino IDE 1.8.1 and 1.8.2 but I get a warning
Compiling library "FSBrowserNG-master"
"/home/sekt/.arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/xtensa-lx106-elf-g++" -D__ets__ -DICACHE_FLASH -U__STRICT_ANSI__ "-I/home/sekt/.arduino15/packages/esp8266/hardware/esp8266/2.3.0/tools/sdk/include" "-I/home/sekt/.arduino15/packages/esp8266/hardware/esp8266/2.3.0/tools/sdk/lwip/include" "-I/tmp/arduino_build_188893/core" -c -Os -g -mlongcalls -mtext-section-literals -fno-exceptions -fno-rtti -falign-functions=4 -std=c++11 -MMD -ffunction-sections -fdata-sections -DF_CPU=80000000L -DLWIP_OPEN_SRC -DARDUINO=10802 -DARDUINO_ESP8266_NODEMCU -DARDUINO_ARCH_ESP8266 -DARDUINO_BOARD="ESP8266_NODEMCU" -DESP8266 "-I/home/sekt/.arduino15/packages/esp8266/hardware/esp8266/2.3.0/cores/esp8266" "-I/home/sekt/.arduino15/packages/esp8266/hardware/esp8266/2.3.0/variants/nodemcu" "-I/home/sekt/.arduino15/packages/esp8266/hardware/esp8266/2.3.0/libraries/ESP8266WiFi/src" "-I/home/sekt/Arduino/libraries/Time-master" "-I/home/sekt/Arduino/libraries/NtpClient-master/src" "-I/home/sekt/Arduino/libraries/ESPAsyncTCP-master/src" "-I/home/sekt/Arduino/libraries/ESPAsyncWebServer-master/src" "-I/home/sekt/.arduino15/packages/esp8266/hardware/esp8266/2.3.0/libraries/ESP8266mDNS" "-I/home/sekt/.arduino15/packages/esp8266/hardware/esp8266/2.3.0/libraries/Ticker" "-I/home/sekt/.arduino15/packages/esp8266/hardware/esp8266/2.3.0/libraries/ArduinoOTA" "-I/home/sekt/Arduino/libraries/ArduinoJson-master" "-I/home/sekt/Arduino/libraries/FSBrowserNG-master" "-I/home/sekt/.arduino15/packages/esp8266/hardware/esp8266/2.3.0/libraries/Hash/src" "/home/sekt/Arduino/libraries/FSBrowserNG-master/FSWebServerLib.cpp" -o "/tmp/arduino_build_188893/libraries/FSBrowserNG-master/FSWebServerLib.cpp.o"
/home/sekt/Arduino/libraries/FSBrowserNG-master/FSWebServerLib.cpp: In member function 'bool AsyncFSWebServer::loadHTTPAuth()':
/home/sekt/Arduino/libraries/FSBrowserNG-master/FSWebServerLib.cpp:363:51: warning: 'const char* ArduinoJson::JsonVariantBase::asString() const [with TImpl = ArduinoJson::JsonObjectSubscript<const char*>]' is deprecated (declared at /home/sekt/Arduino/libraries/ArduinoJson-master/include/ArduinoJson/Deserialization/../JsonVariantBase.hpp:36): use as<char*>() instead [-Wdeprecated-declarations]
_httpAuth.wwwUsername = json["user"].asString();
^
/home/sekt/Arduino/libraries/FSBrowserNG-master/FSWebServerLib.cpp:364:51: warning: 'const char* ArduinoJson::JsonVariantBase::asString() const [with TImpl = ArduinoJson::JsonObjectSubscript<const char*>]' is deprecated (declared at /home/sekt/Arduino/libraries/ArduinoJson-master/include/ArduinoJson/Deserialization/../JsonVariantBase.hpp:36): use as<char*>() instead [-Wdeprecated-declarations]
_httpAuth.wwwPassword = json["pass"].asString();
^
Compiling library "Hash"

from fsbrowserng.

minida28 avatar minida28 commented on July 26, 2024

Argghh I think I've made another duplicate -> #12 .

@sekt1953 can you try change these lines below on FSWebServerLib.cpp file:

    _httpAuth.wwwUsername = json["user"].asString();
    _httpAuth.wwwPassword = json["pass"].asString();

to this

    _httpAuth.wwwUsername = json["user"].as<char*>();
    _httpAuth.wwwPassword = json["pass"].as<char*>();

and see if it fixed your issues.

Also please style your comment, no offense but it's hard to read... 😄 Fence the code with triple back ticks.

from fsbrowserng.

gmag11 avatar gmag11 commented on July 26, 2024

Solved, I hope! thanx

from fsbrowserng.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.