finally
Co-authored-by: Rasmus Karlsson <rasmus.karlsson@pajlada.com>
Also changes the way timeouts happen, since right now if a timeout was met (which it mostly wasn't), it would run the error callback twice causing potentially undefined behaviour