Fixed missing table declaration in where-clause

A recent change (https://github.com/joindin/joindin-api/commit/afb8d6539a1f101c3c5dee05ed645fbc7c5c0452) introduced a bug because it introduced a JOIN which caused an ambiguous "ID"-field. This should fix that.