fix viewer reference