Fixed the bug that would prevent incoming stargates from deactivating properly