Fix broken preview (JS error)