#M-335 Fixed
#M-336 Fixed
Added assertions.