Sort: Fix the component matching

Fixes #5