Merge pull request #759 from cssquirrel/1.3.0

Fixes for bugs M-316 and M-317.