Fixed flag (and flag count)  deletion when node is deleted. Fixed saving/updating/deleting flag counts.
Replaced conditional row creation/update with db_merge().
Added test that flags a node using different user accounts and checks flag counts.
Fix and simplify flag_counts schema
Fix and simplify merge query
Merge pull request #25 from md-systems/fixedFlagDeletionWhenNodeDeleted

#25 by jamescazzetta: Fixed flag (and flag count)  deletion when node is deleted.