Bug fix to reduce false positive detection