Merge pull request #4028 from bjjay/patch-1

Remove a redundant piece of code from Profiler