fix for  SQLite3Result::fetchArray(): The SQLite3Result object has not been correctly initialised in post_addToGroup
revert changes
only connect share hooks if installation OC is installed
Merge pull request #3375 from owncloud/fix_for_SQLite3Result_object_in_post_addToGroup

fix for SQLite3Result::fetchArray() on setup