gettenv gettenv(thread: thread): table? The environment of a thread. Returns nil if the argument is not a thread.