Ey I Need some help with 3/7 get some error :A


#1


https://www.codecademy.com/courses/close-the-super-makert/0/3?curriculum_id=506324b3a7dffd00020bf661#


Ey i don't understand whey i get this error message.
It kind of works look at the console.

Can someone tel me whats wrong?

Error message : Oops, try again. Have you scanned eggs twice and magazine three times?


Replace this line with your code. 

var chasRegister = {
    total: 0,
add: function(itemCost){
    this.total += itemCost;
    },
   
    scan: function (item) {
        switch (item) { 
        case "eggs": 
            this.add(0.98); 
            console.log("bliep");
            break;
        case "milk": 
            this.add(1.23); 
            break;
        case"magazine":
            this.add(4.99);
            console.log("bliep!");
            break;
        case"chocolate":
            this.add(0.45);
            break; 
        }
        
        return true;
    }
};

chasRegister.scan("eggs");
chasRegister.scan("eggs");
chasRegister.scan("magazine");
chasRegister.scan("magazine");
chasRegister.scan("magazine");


console.log('Your bill is ' + chasRegister.total);


#2

you should spell cashRegister correctly


#3

Thanks stetim94 it works fine now ^^


#4