Updated from avalon branch #f41267f