public function hasBranch($branch)
    {
        $branches = $this->getBranches();
        $status = in_array($branch, $branches);

        return $status;
    }
public function hasBranch($branch)
    {
        $branches = $this->getBranches();
        $status = in_array($branch, $branches);

        return $status;
    }
public function hasBranch ( $ branch ) { $ branches = $ this -> getBranches ( ) ; $ status = in_array ( $ branch , $ branches ) ; return $ status ; }
Check if a specified branch exists.

@param  string  $branch Branch to be checked

@return bool True if the branch exists
Check if a specified branch exists .