Fix bug in demo