Maybe clearer if `element` were renamed `filepath`.