duplicated code
Merge pull request #1608 from Dvir-Julius/patch-2

duplicated code same on line 573