Fixing bug in examples