Reuploading from revert
Revert "Reuploading from revert"

This reverts commit 5773ec251ade2786dc8162a0ae4a2bba071db7b6.
Fixing compiler errors (hope this works...)