Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

firebase as module #100

Closed
dominik0711 opened this issue Nov 18, 2015 · 3 comments
Closed

firebase as module #100

dominik0711 opened this issue Nov 18, 2015 · 3 comments

Comments

@dominik0711
Copy link

Hi. I would like to use firebase list as a module to retrieve a list/array of database ids. Could someone give me a hint how to do that?

Thanks in advance!
dominik

@mbleigh
Copy link
Contributor

mbleigh commented Nov 18, 2015

Hey Dominik, check out this section of the README 😄

@mbleigh mbleigh closed this as completed Nov 18, 2015
@dominik0711
Copy link
Author

Hi Michael. Thanks for your comment. I have already read the section but I'll get the following error:
Error: TypeError: Cannot set property 'user' of undefined
I've tried to use the sample code described in the readme:

'use strict';

var dbList = function (options) {
  console.log("Start DbList...");
  var client = require('firebase-tools');
  client.list().then(function(data) {
    console.log(data);
  }).catch(function(err) {
    // handle error
    console.log("Error: " + err);
  });
};

module.exports = dbList;

@canhnht
Copy link

canhnht commented Jul 28, 2016

I got the same error. :( Please re-open this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants