Fixed a bug in the discovery endpoint
Merge branch 'master' into dev