added sharing conditional check to decrement the public collection count