Skip to content

Commit

Permalink
Fix format problem
Browse files Browse the repository at this point in the history
  • Loading branch information
keepwn committed Nov 8, 2018
1 parent 3129107 commit e71a1cb
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
17 changes: 15 additions & 2 deletions src/Exception/BadResponseException.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,20 @@
<?php

namespace ProxmoxVE\Exception;
/**
* This file is part of the ProxmoxVE PHP API wrapper library (unofficial).
*
* @copyright 2014 César Muñoz <[email protected]>
* @license http://opensource.org/licenses/MIT The MIT License.
*/

namespace ProxmoxVE\Exception;

/**
* BadResponseException class. Is the exception thrown when proxmox
* return status_code >= 400, thus the ProxmoxVE API client can not be used.
*
* @author César Muñoz <[email protected]>
*/
class BadResponseException extends \RuntimeException
{
}
}
2 changes: 1 addition & 1 deletion src/Proxmox.php
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ private function processHttpResponse($response)
return null;
}

if($response->getStatusCode() >= 400) {
if ($response->getStatusCode() >= 400) {
throw new BadResponseException($response->getReasonPhrase());
}

Expand Down

0 comments on commit e71a1cb

Please sign in to comment.