fix view code broken in previous bad merge