{"action":"created","issue":{"url":"https://api.github.com/repos/nlohmann/json/issues/704","repository_url":"https://api.github.com/repos/nlohmann/json","labels_url":"https://api.github.com/repos/nlohmann/json/issues/704/labels{/name}","comments_url":"https://api.github.com/repos/nlohmann/json/issues/704/comments","events_url":"https://api.github.com/repos/nlohmann/json/issues/704/events","html_url":"https://github.com/nlohmann/json/issues/704","id":251948470,"number":704,"title":"Issues when adding values to firebase database","user":{"login":"jussihi","id":25184163,"avatar_url":"https://avatars0.githubusercontent.com/u/25184163?v=4","gravatar_id":"","url":"https://api.github.com/users/jussihi","html_url":"https://github.com/jussihi","followers_url":"https://api.github.com/users/jussihi/followers","following_url":"https://api.github.com/users/jussihi/following{/other_user}","gists_url":"https://api.github.com/users/jussihi/gists{/gist_id}","starred_url":"https://api.github.com/users/jussihi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jussihi/subscriptions","organizations_url":"https://api.github.com/users/jussihi/orgs","repos_url":"https://api.github.com/users/jussihi/repos","events_url":"https://api.github.com/users/jussihi/events{/privacy}","received_events_url":"https://api.github.com/users/jussihi/received_events","type":"User","site_admin":false},"labels":[{"id":46374235,"url":"https://api.github.com/repos/nlohmann/json/labels/kind:%20question","name":"kind: question","color":"cc317c","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2017-08-22T13:00:25Z","updated_at":"2017-08-22T15:28:24Z","closed_at":null,"body":"Hello, I'm having some issues adding values to a firebase database using this json library.\r\n\r\nThe test[\"pi\"] adds into the firebase very well, but then when I try to add the test[\"pia\"][\"pia\"] it responds with a  \"error\" : \"Invalid data; couldn't parse JSON object, array, or value.\"\r\n\r\nHere is my code:\r\n\r\n    `json test;\r\n     test[\"pi\"] = 1.41;\r\n     test[\"pia\"][\"pia\"] = 2.0; \r\n     CURLcode res;\r\n     struct curl_slist *headers = NULL;\r\n     headers = curl_slist_append(headers, \"Content-Type: application/json\");\r\n     curl_easy_setopt(curl, CURLOPT_HTTPHEADER, headers);\r\n     curl_easy_setopt(curl, CURLOPT_URL, \"https://aaaa.firebaseio.com/bbbb.json\");\r\n     curl_easy_setopt(curl, CURLOPT_CUSTOMREQUEST, \"PUT\");\r\n     curl_easy_setopt(curl, CURLOPT_POSTFIELDS, moi.dump());\r\n     res = curl_easy_perform(curl);\r\n     std::cout << res << std::endl;\r\n     curl_slist_free_all(headers);\r\n     curl_easy_cleanup(curl);`"},"comment":{"url":"https://api.github.com/repos/nlohmann/json/issues/comments/324062698","html_url":"https://github.com/nlohmann/json/issues/704#issuecomment-324062698","issue_url":"https://api.github.com/repos/nlohmann/json/issues/704","id":324062698,"user":{"login":"nlohmann","id":159488,"avatar_url":"https://avatars2.githubusercontent.com/u/159488?v=4","gravatar_id":"","url":"https://api.github.com/users/nlohmann","html_url":"https://github.com/nlohmann","followers_url":"https://api.github.com/users/nlohmann/followers","following_url":"https://api.github.com/users/nlohmann/following{/other_user}","gists_url":"https://api.github.com/users/nlohmann/gists{/gist_id}","starred_url":"https://api.github.com/users/nlohmann/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nlohmann/subscriptions","organizations_url":"https://api.github.com/users/nlohmann/orgs","repos_url":"https://api.github.com/users/nlohmann/repos","events_url":"https://api.github.com/users/nlohmann/events{/privacy}","received_events_url":"https://api.github.com/users/nlohmann/received_events","type":"User","site_admin":false},"created_at":"2017-08-22T15:28:24Z","updated_at":"2017-08-22T15:28:24Z","body":"Well, storing both in a `std::string` and check if they are equal with `==` should be sufficient. It's just a guess, but the first thing I would try if they \"look\" the same, but treated differently."}}
{"actor":{"display_login":"nlohmann"}}