Make sure to keep the order of input paths in the callback array

Fixes #42