refactor, get rid of `contact_info.get_email2`.

This method was called from exactly one place.
It handled 6 different kind of inputs but the only reference
called with with only 2 distinct inputs. Those inputs then
both share the same duck-type interface.

There is no need for indirection, which is not used.
Merge pull request #228 from 4teamwork/refactor_email2

refactor, get rid of `contact_info.get_email2`.
refactor, get rid of `contact_info.get_email`.

This is a follow up to: #228.

This method was only called from two places.
We inlined both. This allows us to drop this "heavy-switching-logic".
Refactor `contact_info.get_client_of_inbox`:

- Use the `get` method instead of a filter_query statement.
- Drop unnecessary determination (queries on the primary_key only returns 0 or 1 result).
Merge pull request #229 from 4teamwork/refactor

refactor, get rid of `contact_info.get_email`.
Merge pull request #230 from 4teamwork/refactor_get_client_of_inbox

Refactor `contact_info.get_client_of_inbox`:
Change client query using `get` instead of `filter_by`.
manual revert of 26302a50. That "workaround" is not required.

There was a check to work around collation issues with Oracle.
The reason to add this behavior, were duplicated records with different case.
The `clients` table is only filled by opengever. We need to maintain consistency
of case ourselves to make quering easy. Having two records with the same primary_key
in different case is going to break the application anyway.

/cc @lukasgraf
use `get` when only filtering by primary key.
Reworked is_group_member, so that it only use one query.
Refactor get_user_sort_dict.
consistend use of `filter_by` for single table queries.
`get_group_of_inbox` returns `Group` object.

As the name suggests, this method fetches the whole group.
However it only returns the `groupid`. This patch returns
the complete group object instead.