Fix the current-buffer checks the functions do

Instead of checking that b:merginal_repo exists, check the buffer name
to make sure the user is in the correct type Merginal buffer and not
only that they are in a Merginal buffer.