use rugged_check_repo everywhere

The usage in `rugged_branch.c` is fixed in #242