Make it safe for calling render multiple times.