| @@ 105-113 (lines=9) @@ | ||
| 102 | * |
|
| 103 | * @return string|boolean |
|
| 104 | */ |
|
| 105 | public function getAccountId() |
|
| 106 | { |
|
| 107 | if ($this->input->getOption('id')) { |
|
| 108 | return $this->input->getOption('id'); |
|
| 109 | } elseif ($this->getConfig()->getAccountId()) { |
|
| 110 | return $this->getConfig()->getAccountId(); |
|
| 111 | } |
|
| 112 | throw new \InvalidArgumentException('You must specify or configure an account id'); |
|
| 113 | } |
|
| 114 | ||
| 115 | /** |
|
| 116 | * Get the access token specified, or from the config |
|
| @@ 120-128 (lines=9) @@ | ||
| 117 | * |
|
| 118 | * @return string|boolean |
|
| 119 | */ |
|
| 120 | public function getAccessToken() |
|
| 121 | { |
|
| 122 | if ($this->input->getOption('token')) { |
|
| 123 | return $this->input->getOption('token'); |
|
| 124 | } elseif ($this->getConfig()->getAccessToken()) { |
|
| 125 | return $this->getConfig()->getAccessToken(); |
|
| 126 | } |
|
| 127 | throw new \InvalidArgumentException('You must specify or configure an access token'); |
|
| 128 | } |
|
| 129 | ||
| 130 | /** |
|
| 131 | * Get the user's config |
|