Revert "Revert "Bug Fix""

This reverts commit 7d5674fbe156789ff41962404f6005d674fc16f4.