Issue #2916754 by chr.fritsch, borisson_, drunken monkey: Fixed failure to detect whether a view is executed in the current request.