Correct undefined variable in post_shared hook, fixes #2592
Initialize collectionTypes variable as false
Merge pull request #2781 from owncloud/fix-2592

Correct undefined variable in post_shared hook, fixes #2592