This is required to run deferred teardown functions
Co-authored-by: AlteredCoder Co-authored-by: erenJag