Check if the ID is a string and convert to ObjectId

Signed-off-by: Dominic Böttger <Dominic.Boettger@inspirationlabs.com>