Skip to content

NameError (uninitialized constant ChatsController::Firebase) #102

@Rico-Qbit

Description

@Rico-Qbit

Hello, I'm just learn ruby and want to try integrate firebase with my api using this package. When I tried to make a post request to my create api, I got this error message:
`NameError (uninitialized constant ChatsController::Firebase

            firebase = Firebase::Client.new(base_uri)
                       ^^^^^^^^):`

Looks like something is wrong with the package maybe? Here is my api code looks like :
def create base_uri = <my firebase url> firebase = Firebase::Client.new(base_uri) response = firebase.push("messages", { :message_text => params[:message_text], :time => Firebase::ServerValue::TIMESTAMP, :username => params[:username] }) end

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions