Fixes issue #502
Fixes issue #502
Merge pull request #685 from Alex-van-der-Peet/RESTAPIFix

Fixes Issue #502