Bill (1) [Avatar] Offline
#1
In listing 4.7 you have the code as follows

Template.selectHouse.helpers({
    housesNameId: function(){
        return HousesCollection.find({}, {});
    },
    // Returns selected if the _id for current processed house equals that stored inside the Session variable
    isSelected: function(){
        return Session.equals('selectedHouseId', this._id) ? 'selected' : '';
    }
});

Template.selectHouse.events({
   // Remember to pass the event as an argument so the function can assign the selection value to the Session variable
   'change #selectHouse': function(evt){
       Session.set('selectedHouseId', evt.currentTarget.value);
   }
});


Now on Figure 4.6 you have a picture of the browser console with the follow code submitted.

Session.get("selectedHouse")
Session.get("selectedHouse")
Session.set("selectedHouse", " *Session Key ID* ")

Shouldn't the session name be 'selectedHouseId' when running it in the browser console.

Thought I should point it out before it gets officially published
stephan.hochhaus (92) [Avatar] Offline
#2
Thanks, will take care of the fix.