A witness, including a witness specified in subdivision (b) of Section 1987, is not obliged to attend as a witness before any court, judge, justice or any other officer, unless the witness is a resident within the state at the time of service.
(Amended by Stats. 1981, Ch. 184, Sec. 3.)