mobizt/Firebase-Arduino-WiFiNINA

Too many ")" within the "READ" example code

graybright opened this issue · 1 comments

Within the section Read, Store, Update, Delete, Backup and Restore Data there is some example code, and the following line has one too many brackets ")". Deleting one bracket ")" resolves the code.

if (firebaseData.dataType() == "int")) {

This was from the example code below - PS Thanks for the awesome work you've done!!!

Here is the example usage to read integer value from defined database path "/test/int".

//Read integer value from database at "/test/int" 

  int val = 0;

  if (Firebase.getInt(firebaseData, "/test/int")) {

    //Success, then read the payload value

    //Make sure payload value returned from server is integer
    //This prevent you to get garbage data
    if (firebaseData.dataType() == "int")) {
      val = firebaseData.intData();
      Serial.println(val);
    }

  } else {
    //Failed, then print out the error detail
    Serial.println(firebaseData.errorReason());
  }

Thank you for the information.

It's just typo in readme doc.