Skip to content

Commit

Permalink
Standardize whitespace to tabs
Browse files Browse the repository at this point in the history
CodeIgniter Style Guide:
http://codeigniter.com/user_guide/general/styleguide.html

Ran the following:

    $ find . -type f -name "*.php" -print | \
      xargs ruby -i -p -e \
      '$_.gsub!(/^(    )+/) {|m| "\t" * (m.size/4)}'
  • Loading branch information
Neuman Vong committed Oct 20, 2010
1 parent 28ccedb commit a226b7e
Show file tree
Hide file tree
Showing 70 changed files with 2,318 additions and 2,318 deletions.
2 changes: 1 addition & 1 deletion OpenVBX/controllers/accounts.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ function __construct()
$this->template->write('title', 'Users');
$this->load->model('vbx_device');
}
public function index()
{
$this->template->add_js('assets/j/accounts.js');
Expand Down
6 changes: 3 additions & 3 deletions OpenVBX/controllers/auth/login.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ public function index()

if($this->session->userdata('loggedin'))
{
if(VBX_User::signature($this->user_id) == $this->session->userdata('signature'))
return $this->redirect($redirect);
if(VBX_User::signature($this->user_id) == $this->session->userdata('signature'))
return $this->redirect($redirect);
}

$this->template->write('title', 'Log In');
Expand Down Expand Up @@ -100,7 +100,7 @@ private function login($redirect)
'user_id' => $user->id,
'is_admin' => $user->is_admin,
'loggedin' => TRUE,
'signature' => VBX_User::signature($user->id),
'signature' => VBX_User::signature($user->id),
);

$this->session->set_userdata($userdata);
Expand Down
2 changes: 1 addition & 1 deletion OpenVBX/controllers/auth/logout.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ private function logout()
{

$this->session->sess_destroy();
$this->session->set_userdata('loggedin', false);
$this->session->set_userdata('loggedin', false);

$data = array('error' => 'You have been logged out.',
'redirect' => '',
Expand Down
22 changes: 11 additions & 11 deletions OpenVBX/controllers/connect.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
class Connect extends User_Controller
{
private $new_number = null;
public function __construct()
public function __construct()
{
parent::__construct();
$this->load->library('applet');
Expand All @@ -32,16 +32,16 @@ public function __construct()
}


public function index()
{
$data = $this->init_view_data();
$flows = VBX_Flow::search();
public function index()
{
$data = $this->init_view_data();
$flows = VBX_Flow::search();

$numbers = array();
try
{
$numbers = $this->vbx_incoming_numbers->get_numbers();
}
}
catch (VBX_IncomingNumberException $e)
{
$this->error_message = ErrorMessages::message('twilio_api', $e->getCode());
Expand Down Expand Up @@ -84,7 +84,7 @@ public function index()

}
$data['numbers'] = $incoming_numbers;
$data['flows'] = $flows;
$data['flows'] = $flows;
$data['twilio_sid'] = $this->twilio_sid;

if(empty($this->error_message))
Expand All @@ -103,7 +103,7 @@ public function index()

$data['counts'] = $this->message_counts();

return $this->respond('', 'connect', $data);
}
return $this->respond('', 'connect', $data);
}
}
10 changes: 5 additions & 5 deletions OpenVBX/controllers/devices.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,16 +121,16 @@ public function password()
else
{
$user->password = VBX_User::salt_encrypt($new_pw);
try
{
$user->save();
try
{
$user->save();
$message = 'Password changed';
}
catch(VBX_UserException $e)
{
$this->data['error'] = true;
$message = 'Unable to set password, please try again later.';
error_log($e->getMessage());
error_log($e->getMessage());
}
}
$this->data['message'] = $message;
Expand Down Expand Up @@ -199,7 +199,7 @@ private function update_number($device_id)
}
catch(VBX_DeviceException $e)
{
error_log($e->getMessage());
error_log($e->getMessage());
$device['json']['error'] = true;
$device['json']['message'] = 'Unable to update device settings';
}
Expand Down
24 changes: 12 additions & 12 deletions OpenVBX/controllers/numbers.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ function index()
try
{
$numbers = $this->vbx_incoming_numbers->get_numbers();
}
}
catch (VBX_IncomingNumberException $e)
{
$this->error_message = ErrorMessages::message('twilio_api', $e->getCode());
Expand Down Expand Up @@ -144,8 +144,8 @@ function delete($phone_id)
{
$confirmed = $this->input->post('confirmed');
$data['confirmed'] = $confirmed;
$data['error'] = false;
$data['message'] = '';
$data['error'] = false;
$data['message'] = '';
try
{
if(!$confirmed)
Expand All @@ -158,14 +158,14 @@ function delete($phone_id)
throw new NumberException('Malformed Phone identifier.');
}

try
{
$this->vbx_incoming_numbers->delete_number($phone_id);
}
catch(VBX_IncomingNumberException $e)
{
throw new NumberException($e->getMessage());
}
try
{
$this->vbx_incoming_numbers->delete_number($phone_id);
}
catch(VBX_IncomingNumberException $e)
{
throw new NumberException($e->getMessage());
}
}
catch(NumberException $e)
{
Expand Down Expand Up @@ -265,7 +265,7 @@ private function get_outgoingcallerid()
try
{
$numbers = $this->vbx_incoming_numbers->get_numbers();
}
}
catch (VBX_IncomingNumberException $e)
{
$this->error_message = ErrorMessages::message('twilio_api', $e->getCode());
Expand Down
12 changes: 6 additions & 6 deletions OpenVBX/errors/error_404.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ function curPageURL() {
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="ROBOTS" content="NOINDEX, NOFOLLOW" />

<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/reset-fonts-grids-2.8.css" />
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/global.css" />
<!--[if IE 7]>
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/ie.css" />
<![endif]-->
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/reset-fonts-grids-2.8.css" />
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/global.css" />
<!--[if IE 7]>
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/ie.css" />
<![endif]-->
</head>

<body>
Expand Down
12 changes: 6 additions & 6 deletions OpenVBX/errors/error_db.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ function curPageURL() {
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="ROBOTS" content="NOINDEX, NOFOLLOW" />

<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/reset-fonts-grids-2.8.css" />
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/global.css" />
<!--[if IE 7]>
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/ie.css" />
<![endif]-->
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/reset-fonts-grids-2.8.css" />
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/global.css" />
<!--[if IE 7]>
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/ie.css" />
<![endif]-->
</head>

<body>
Expand Down
12 changes: 6 additions & 6 deletions OpenVBX/errors/error_general.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ function curPageURL() {
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="ROBOTS" content="NOINDEX, NOFOLLOW" />

<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/reset-fonts-grids-2.8.css" />
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/global.css" />
<!--[if IE 7]>
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/ie.css" />
<![endif]-->
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/reset-fonts-grids-2.8.css" />
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/global.css" />
<!--[if IE 7]>
<link type="text/css" rel="stylesheet" href="<?php echo ASSET_ROOT ?>/c/ie.css" />
<![endif]-->
</head>

<body>
Expand Down
Loading

0 comments on commit a226b7e

Please sign in to comment.