yes, I have this on the client. But I suspect that my whole server side publication code is not executed? ps, do you also know what .added means I can’t find anything on google for this.
in imports/ui
import { Template } from 'meteor/templating';
import { Customers } from '../api/customers.js';
import { Session } from 'meteor/session';
// import * from '/lib/globalHelpers.js';
import './body.html';
import './customer.js';
import moment from 'moment';
import lodash from 'lodash';
_ = lodash;
// set Session variable in method callback
Meteor.call('getApps', function(error, result){
Session.set('qApps', result);
});
Meteor.call('getStreams', function(error, result){
Session.set('qStreams', result);
// console.log('de loaded apps from sense are: ', result);
});
Meteor.call('countApps', function(error, result){
Session.set('countApps', result.value);
console.log('count of apps:', result);
});
Meteor.call('countStreams', function(error, result){
Session.set('countStreams', result.value);
});
//subscribe to the Sense apps publication, so that if Sense updates meteor will update too
Apps = new Mongo.Collection('apps');
Session.setDefault('searching', false);
Tracker.autorun(function() {
if (Session.get('apps')) {
var searchHandle = Meteor.subscribe('apps');
Session.set('searching', ! searchHandle.ready());
}
});
also, I would like to log the object I get back from the API, but I use to get memory exceeded errors, do you maybe have some best practices for that or do I just have to make the resultset smaller?