step-up-labs / firebase-database-dotnet

C# library for Firebase Realtime Database.
MIT License
668 stars 168 forks source link

Trying to update an item #280

Closed eduardoagr closed 2 years ago

eduardoagr commented 2 years ago

Hello I a trying to update a specific item an I get this error

Firebase.Database.FirebaseException: 'Exception occured while processing the request. Url: Couldn't build the url Request Data: { "Name" : "dewdewdewdwedwe" } Response: '

This is the code I m using

`public async void UpdateNoteBookTitleAsync(string Id, string NotebookName) {

        await firebaseClient
            .Child(AppConstant.Notebooks)
            .Child(Id)
            .PatchAsync($"{{ \"Name\" : \"{NotebookName}\" }}");
    }`

My DB structure

{ "Notebooks" : { "-MyIHc6fDJtRbQ7GFzip" : { "Color" : "#FFFFA500", "CreatedDate" : "Wednesday, March 16, 2022", "Name" : "edu", "UserID" : "wqjizNNCMQdbHoO5bEpd0pYa0Mh2" } } }