Updated to handle both mod.it and server code without needing to do anything special