[profiler] Remove an unnecessary check that could hide potential bugs.