Fix comparison of registration_id

Fixes #193