replaced syntax errors (missings 'var')