Add owncloud version to JS scope

Fix #5361