Another look at the martingale theorem