```ruby
require 'English'

module GitTracker
  module Branch
    def self.story_number
      current[/#?(?<number>\d+)/, :number]
    end

    def self.current
      branch_path = `git symbolic-ref HEAD`

      abort unless $CHILD_STATUS.exitstatus == 0

      branch_path[%r{refs/heads/(?<name>.+)}, :name] || ''
    end
  end
end
```

Refactor to a named method, for sanity
user
```ruby
require 'English'

module GitTracker
  module Branch
    def self.story_number
      current[/#?(?<number>\d+)/, :number]
    end

    def self.current
      branch_path = `git symbolic-ref HEAD`

      abort unless exit_successful?

      branch_path[%r{refs/heads/(?<name>.+)}, :name] || ''
    end

    private

    def self.exit_successful?
      $CHILD_STATUS.exitstatus == 0
    end
  end
end
```
assistant