<NME> aws.php
<BEF> <?php
class AmazonS3
{
  const ACL_PUBLIC = 1;
  const ACL_PRIVATE = 1;
  const REGION_US_E1 = 1;
}

class CFPolicy
{

}

class AWSSuccessResponse
{
  public function isOK()
  {
    return true;
  }

  public function areOK()
  {
    return true;
  }
}


class AWSFailureResponse
{
  public $body;
  public function __construct()
  {
    $this->body = new stdClass;
    $this->body->Errors = array();
  }

  public function isOK()
  {
    return false;
  }

  public function areOK()
  {
    return false;
  }
}

class AWSBatchSuccessResponse extends AWSSuccessResponse
{
  private $type, $count;
  public function __construct($type = null, $count = 0)

  public function create_domain()
  {
    return new AWSSuccessResponse;    
  }

  public function create_object()
  {
    return new AWSSuccessResponse;    
  }

  public function put_attributes()
    return true;
  }

  public function send()
  {
    return $this->returnByType();
  }

  public function create_domain()
  {
    return new AWSSuccessResponse;
  }

  public function create_object()
  {
        $retval = array(new AWSPhotoMockSdb($this->count));
        break;
      default:
        $retval = new AWSSuccessResponse;    
        break;
    }
    return $retval;

  public function select()
  {
    return $this->returnByType();
  }

  private function returnByType()
  {
    $retval = null;
    switch($this->type)
    {
      case 'photo':
        $retval = array(new AWSPhotoMockSdb($this->count));
        break;

  public function send()
  {
    return new AWSFailureResponse;    
  }

  public function put_attributes()

class AWSBatchFailureResponse extends AWSFailureResponse
{

  public function create_object()
  {
    return new AWSFailureResponse;    
  }
}

    return new AWSFailureResponse;
  }

  public function send()
  {
    return new AWSFailureResponse;
  }

  public function put_attributes()
  {
    return false;
  }

  public function create_object()
  {
    return new AWSFailureResponse;
  }
}

class AWSCredentialMockSdb extends AWSSuccessResponse
{
  public $body;
  public function __construct()
  {
    $this->body = new stdClass;
    $this->body->SelectResult = new stdClass;
    $this->body->SelectResult->Item = new stdClass;
    $this->body->SelectResult->Item->Name = 'foo';
    $this->body->SelectResult->Item->Attribute = array(
      $this->attr('name', 'unittest'),
      $this->attr('clientSecret', 'clientSecret'),
      $this->attr('userToken', 'userToken')
    );

  }

  private function attr($name, $value)
  {
    $ret = new stdClass;
    $ret->Name = $name;
    $ret->Value = $value;
    return $ret;
  }
}

class AWSGroupMockSdb extends AWSSuccessResponse
{
  public $body;
  public function __construct($count = 1)
  {
    $this->body = new stdClass;
    $this->body->SelectResult = new stdClass;
    if($count == 1)
    {
      $this->body->SelectResult->Item = new stdClass;
      $this->body->SelectResult->Item->Name = 'foo';
      $this->body->SelectResult->Item->Attribute = array(
        $this->attr('name', 'clientSecret'),
        $this->attr('members', array('user@test.com', 'foo@bar.com'))
      );
    }
    elseif($count > 1)
    {
      $this->body->SelectResult->Item = array();
      for($i=0; $i<$count; $i++)
      {
        $this->body->SelectResult->Item[$i] = new stdClass;
        $this->body->SelectResult->Item[$i]->Name = 'foo';
        $this->body->SelectResult->Item[$i]->Attribute = array(
          $this->attr('name', 'clientSecret'),
          $this->attr('members', array('user@test.com', 'foo@bar.com'))
        );
      }
    }
  }

  private function attr($name, $value)
  {
    $ret = new stdClass;
    $ret->Name = $name;
    $ret->Value = $value;
    return $ret;
  }
}

class AWSPhotoMockSdb extends AWSSuccessResponse
{
  public $body;
  public function __construct()
  {
    $this->body = new stdClass;
    $this->body->SelectResult = new stdClass;
    $this->body->SelectResult->Item = new stdClass;
    $this->body->SelectResult->Item->Name = 'foo';
    $this->body->SelectResult->Item->Attribute = array(
      $this->attr('host', 'unittest'),
      $this->attr('dateTaken', time())
    );

  }

  private function attr($name, $value)
  {
    $ret = new stdClass;
    $ret->Name = $name;
    $ret->Value = $value;
    return $ret;
  }
}

class AWSTagMockSdb extends AWSSuccessResponse
{
  public $body;
  public function __construct($count = 1)
  {
    $this->body = new stdClass;
    $this->body->SelectResult = new stdClass;
    if($count == 1)
    {
      $this->body->SelectResult->Item = new stdClass;
      $this->body->SelectResult->Item->Name = 'foo';
      $this->body->SelectResult->Item->Attribute = array(
        $this->attr('count', 1)
      );
    }
    elseif($count > 1)
    {
      $this->body->SelectResult->Item = array();
      for($i=0; $i<$count; $i++)
      {
        $this->body->SelectResult->Item[$i] = new stdClass;
        $this->body->SelectResult->Item[$i]->Name = "foo{$i}";
        $this->body->SelectResult->Item[$i]->Attribute = array(
          $this->attr('count', 1)
        );
      }
    }
  }

  private function attr($name, $value)
  {
    $ret = new stdClass;
    $ret->Name = $name;
    $ret->Value = $value;
    return $ret;
  }
}

class AWSUserMockSdb extends AWSSuccessResponse
{
  public $body;
  public function __construct()
  {
    $this->body = new stdClass;
    $this->body->SelectResult = new stdClass;
    $this->body->SelectResult->Item = new stdClass;
    $this->body->SelectResult->Item->Name = 'foo';
    $this->body->SelectResult->Item->Attribute = array(
      $this->attr('lastPhotoId', 1),
      $this->attr('lastActionId', 2),
      $this->attr('version', '1.0.0')
    );
  }

  private function attr($name, $value)
  {
    $ret = new stdClass;
    $ret->Name = $name;
    $ret->Value = $value;
    return $ret;
  }
}

<MSG> Merge branch 'master' of github.com:openphoto/frontend

<DFF> @@ -52,12 +52,12 @@ class AWSBatchSuccessResponse extends AWSSuccessResponse
 
   public function create_domain()
   {
-    return new AWSSuccessResponse;    
+    return new AWSSuccessResponse;
   }
 
   public function create_object()
   {
-    return new AWSSuccessResponse;    
+    return new AWSSuccessResponse;
   }
 
   public function put_attributes()
@@ -79,7 +79,7 @@ class AWSBatchSuccessResponse extends AWSSuccessResponse
         $retval = array(new AWSPhotoMockSdb($this->count));
         break;
       default:
-        $retval = new AWSSuccessResponse;    
+        $retval = new AWSSuccessResponse;
         break;
     }
     return $retval;
@@ -100,7 +100,7 @@ class AWSBatchFailureResponse extends AWSFailureResponse
 
   public function send()
   {
-    return new AWSFailureResponse;    
+    return new AWSFailureResponse;
   }
 
   public function put_attributes()
@@ -110,7 +110,7 @@ class AWSBatchFailureResponse extends AWSFailureResponse
 
   public function create_object()
   {
-    return new AWSFailureResponse;    
+    return new AWSFailureResponse;
   }
 }
 

{'commit': 'diff --git a/Readme.markdown b/Readme.markdown\nindex 052710d3..855d27a5 100644\n--- a/Readme.markdown\n+++ b/Readme.markdown\n@@ -13,7 +13,7 @@\n ### How does OpenPhoto work?\n \n OpenPhoto works similarly to Flickr, Smugmug and other photo sharing services with one major difference: you retain ownership and give OpenPhoto access to use them.\n-All photos, tags and comments are stored in your personal cloud accounts with companies like Amazon, Rackspace or Google. \n+All photos, tags and comments are stored in your personal cloud accounts with companies like Amazon, Rackspace or Google.\n This means you can easily switch between OpenPhoto services, use more than one at a time or stop using them altogether while retaining all of your photos, tags and comments.\n \n ----------------------------------------\n@@ -22,15 +22,15 @@ This means you can easily switch between OpenPhoto services, use more than one a\n \n While OpenPhoto functions like many existing services it\'s drastically different for several reasons.\n \n-1.  **Ownership**  \n+1.  **Ownership**\n     Users can specify where their photos are stored. By default they are seamlessly stored in your [Amazon S3][s3] bucket.\n-1.  **Built in backups**  \n+1.  **Built in backups**\n     Since you upload photos to your own [Amazon S3][s3] bucket it\'s like uploading and archiving your photos in one step.\n-1.  **Portability**  \n+1.  **Portability**\n     Easily start off by signing up for a hosted OpenPhoto account and later switch to hosting the software yourself. There\'s no need to transfer your photos somewhere else since it\'s federated. It\'s like plug and play.\n-1.  **Durability**  \n+1.  **Durability**\n     Your photos are not tied to any particular photo service. Because everything is open you can write your own web interface for your photos, choose between OpenPhoto hosting providers or install the OpenPhoto software on your own server.\n-1.  **Community**  \n+1.  **Community**\n     New features will be entirely community driven. Features with the most votes will get top priority in getting implemented. If you want a feature that doesn\'t have many votes you can implement it yourself and issue a pull request.\n \n ----------------------------------------\ndiff --git a/documentation/api/Envelope.markdown b/documentation/api/Envelope.markdown\nindex 3f065b4d..dd5f7ab4 100644\n--- a/documentation/api/Envelope.markdown\n+++ b/documentation/api/Envelope.markdown\n@@ -16,13 +16,13 @@ Every API returns a JSON response adhering to the following format.\n \n #### Message\n \n-The _message_ is a string which describes the action taken. \n+The _message_ is a string which describes the action taken.\n It\'s purely for informational purposes and should never be used in your code or relied on.\n \n #### Code\n \n-The _code_ is an integer representing the status of the API call. \n-Typically the _code_ value should be _200_ but anything between _200_ and _299_ indicates a successful response. \n+The _code_ is an integer representing the status of the API call.\n+Typically the _code_ value should be _200_ but anything between _200_ and _299_ indicates a successful response.\n The photo upload API, for example, will return a _202_ response indicating that the resource has been created.\n \n Below are some common codes:\n@@ -35,7 +35,7 @@ Below are some common codes:\n \n #### Result\n \n-The _result_ can be any simple or complex value. \n-Consult the documentation for the endpoint you\'re using for information on what the _result_ will be. \n-The purpose of the _result_ is to allow you to continue processing the request. \n+The _result_ can be any simple or complex value.\n+Consult the documentation for the endpoint you\'re using for information on what the _result_ will be.\n+The purpose of the _result_ is to allow you to continue processing the request.\n We\'ll try to return the information you\'ll most likely need and aim to keep you from having to make a subsequent call to get it.\ndiff --git a/documentation/api/GetPhotoNextPrevious.markdown b/documentation/api/GetPhotoNextPrevious.markdown\nindex 0d601590..ab5e355c 100644\n--- a/documentation/api/GetPhotoNextPrevious.markdown\n+++ b/documentation/api/GetPhotoNextPrevious.markdown\n@@ -72,7 +72,7 @@ The response is in a standard [response envelope][Envelope].\n       "result" : {\n         "previous" : {\n           "tags" : [\n-            \n+\n           ],\n           "id" : "bo",\n           "appId" : "openphoto-frontend",\n@@ -109,7 +109,7 @@ The response is in a standard [response envelope][Envelope].\n         },\n         "next" : {\n           "tags" : [\n-            \n+\n           ],\n           "id" : "63",\n           "appId" : "current.openphoto.me",\ndiff --git a/documentation/api/GetPhotos.markdown b/documentation/api/GetPhotos.markdown\nindex 2632de13..cda55e8b 100644\n--- a/documentation/api/GetPhotos.markdown\n+++ b/documentation/api/GetPhotos.markdown\n@@ -34,7 +34,7 @@ _Authentication: optional_\n <a name="parameters"></a>\n ### Parameters\n \n-1.  returnSizes (optional), The photo sizes you\'d like in the response. Specify every size you plan on using. [Docs for this parameter][ReturnSizes] \n+1.  returnSizes (optional), The photo sizes you\'d like in the response. Specify every size you plan on using. [Docs for this parameter][ReturnSizes]\n 1.  pageSize (optional), Number of photos to return per request.\n 1.  page (optional), Page number when browsing through photos. Starts at 1.\n 1.  tags (optional), _i.e. dog,cat_ - A comma delimited string of strings.\ndiff --git a/documentation/api/GetTags.markdown b/documentation/api/GetTags.markdown\nindex 574a07f5..47581c2c 100644\n--- a/documentation/api/GetTags.markdown\n+++ b/documentation/api/GetTags.markdown\n@@ -86,7 +86,7 @@ The response is in a standard [response envelope][Envelope].\n         },\n         {\n           "id": "Sunnyvale",\n-          "count":23 \n+          "count":23\n           "latitude": 13.579,\n           "longitude": 24.68\n         },\ndiff --git a/documentation/api/PostPhotoUpdate.markdown b/documentation/api/PostPhotoUpdate.markdown\nindex dc86ae04..9dc886e8 100644\n--- a/documentation/api/PostPhotoUpdate.markdown\n+++ b/documentation/api/PostPhotoUpdate.markdown\n@@ -18,7 +18,7 @@ Open Photo API / Photo Upload\n <a name="purpose"></a>\n ### Purpose of the Photo update API\n \n-This API is used to update an existing photo\'s metadata for a user. \n+This API is used to update an existing photo\'s metadata for a user.\n \n ----------------------------------------\n \ndiff --git a/documentation/api/PostPhotoUpload.markdown b/documentation/api/PostPhotoUpload.markdown\nindex 60f1f653..17efd625 100644\n--- a/documentation/api/PostPhotoUpload.markdown\n+++ b/documentation/api/PostPhotoUpload.markdown\n@@ -18,7 +18,7 @@ Open Photo API / Photo Upload\n <a name="purpose"></a>\n ### Purpose of the Photo Upload API\n \n-This API is used to upload a new photo for a user. \n+This API is used to upload a new photo for a user.\n \n ----------------------------------------\n \ndiff --git a/documentation/faq/Faq.markdown b/documentation/faq/Faq.markdown\nindex 03cfece8..23832f19 100644\n--- a/documentation/faq/Faq.markdown\n+++ b/documentation/faq/Faq.markdown\n@@ -2,7 +2,7 @@ Documentation\n =======================\n #### OpenPhoto, a photo service for the masses\n \n-This is a list of common questions that people have about OpenPhoto. \n+This is a list of common questions that people have about OpenPhoto.\n If you have one which is not on this list send us a message via <a href="http://twitter.com/openphoto">Twitter</a> or <a href="mailto:hello@openphoto.me">email</a>.\n \n ### What exactly is OpenPhoto?\n@@ -11,33 +11,33 @@ The short answer is that OpenPhoto is a way to store and share your photos witho\n \n The long answer is that OpenPhoto consists of two parts: a specification and an implementation.\n \n-The specification is a set of guidelines that define exactly how your photos are stored, how they are accessed and much more. \n-This helps make the entire system open and enables other developers to build functionality on top of your photos. \n+The specification is a set of guidelines that define exactly how your photos are stored, how they are accessed and much more.\n+This helps make the entire system open and enables other developers to build functionality on top of your photos.\n The documentation makes up the majority of the specification.\n \n-The implementation is code which adheres to the specification and provides functionality. \n-The OpenPhoto.me website is an example where the funtionality provided is the ability to store and share photos. \n-Another example would be if a developer created an Instagram like application adhering to the specification. \n+The implementation is code which adheres to the specification and provides functionality.\n+The OpenPhoto.me website is an example where the funtionality provided is the ability to store and share photos.\n+Another example would be if a developer created an Instagram like application adhering to the specification.\n That would be another implementation which provides the functionality of easily sharing photos from your phone with filters.\n \n ----------------------------------------\n \n ### What makes OpenPhoto different from Flickr, Smugmug, iCloud or any other service?\n \n-Normally you pay one company to store your photos and to provide services to share them. \n+Normally you pay one company to store your photos and to provide services to share them.\n This means that you can\'t do much if they raise their prices, shut down their service or another site comes along.\n \n-These sites may offer APIs but they typically enable addon services and rarely competing services. \n+These sites may offer APIs but they typically enable addon services and rarely competing services.\n Your photos are still stored on the company\'s servers who provide the base service.\n \n-With OpenPhoto you can switch between services, use more than one at a time or stop using the service and continue to have your photos stored. \n+With OpenPhoto you can switch between services, use more than one at a time or stop using the service and continue to have your photos stored.\n \n ----------------------------------------\n \n ### If OpenPhoto is open sourced then why isn\'t it free?\n \n-For clarity, OpenPhoto is both free and open sourced (FOSS). \n-Typically what you end up paying for is storage from someone like Amazon or Rackspace. \n+For clarity, OpenPhoto is both free and open sourced (FOSS).\n+Typically what you end up paying for is storage from someone like Amazon or Rackspace.\n \n Amazon offers 5GB of storage for free which means if you don\'t need any additional space then using OpenPhoto is entirely free.\n \ndiff --git a/documentation/faq/Glossary.markdown b/documentation/faq/Glossary.markdown\nindex 21aab4c2..9496b6cd 100644\n--- a/documentation/faq/Glossary.markdown\n+++ b/documentation/faq/Glossary.markdown\n@@ -4,15 +4,15 @@ OpenPhoto / Glossary\n \n The OpenPhoto stack consists of various components. Below is a glossary of all the terms you need to know so you can understand the overall system.\n \n-1.  **Amazon S3**  \n+1.  **Amazon S3**\n     [Amazon S3][s3] stands for Simple Storage Service.\n-1.  **Amazon SimpleDb**  \n+1.  **Amazon SimpleDb**\n     [Amazon SimpleDb][simpledb] is a non-relational database system.\n-1.  **Data Source**  \n+1.  **Data Source**\n     The Data Source stores all textual data for a given user. Each user\'s Data Source may be different. The default Data Source is data.openphoto.me as a CNAME to [Amazon SimpleDb][simpledb].\n-1.  **File System**  \n+1.  **File System**\n     The File System stores all high and low resolution photos for a given user. Each user\'s File System may be different. The default File System is file.openphoto.me as a CNAME to [Amazon S3][s3].\n-1.  **Adapter**  \n+1.  **Adapter**\n     Adapters are middleware that allows the base system to communicate with various Data Sources and File Systems. Adapters exist for [Amazon S3][s3] and [Amazon SimpleDb][simpledb].\n 1.  **Open Photo API**\n     [The Open Photo API][openphotoapi] which this software is built on and also allows others to build applications on top of.\ndiff --git a/documentation/faq/PhotoGeneration.markdown b/documentation/faq/PhotoGeneration.markdown\nindex fd23f08f..086e204d 100644\n--- a/documentation/faq/PhotoGeneration.markdown\n+++ b/documentation/faq/PhotoGeneration.markdown\n@@ -17,7 +17,7 @@ This call returns the following response.\n     {\n       "code" : 200,\n       "message" : "Photo 63",\n-      "result" : { \n+      "result" : {\n         "appId" : "current.openphoto.me",\n         "creativeCommons" : "BY-NC",\n         "dateTaken" : "1313010850",\n@@ -57,10 +57,10 @@ The most important keys in the response are `path123x123` and `path200x200`. Eit\n \n It\'s important to realize that the photo isn\'t generated and stored until this URL is called. This typically happens when the browser tries to display this photo. Once that has happened then the _123x123_ version exists both in the database and file system and calling the same API again returns a different URL for `path123x123`.\n \n-    { \n+    {\n       "code" : 200,\n       "message" : "Photo 63",\n-      "result" : { \n+      "result" : {\n         "appId" : "current.openphoto.me",\n         "creativeCommons" : "BY-NC",\n         "dateTaken" : "1313010850",\n@@ -99,7 +99,7 @@ The URL for `path123x123` now points to a static resource.\n You can specify multiple sizes for the `returnSizes` delimited by commas.\n \n     curl "http://current.openphoto.me/photo/63.json?returnSizes=123x123,300x300xBW"\n-    \n+\n ### Understanding options for returnSizes\n \n The `returnSizes` parameter takes values in the form of _WxH[[xA]xB]_ which means it starts with a numeric _width_ and _height_. The most simple form is limited to specifying just a _width_ and _height_. This looks like `200x200` or `125x300`.\ndiff --git a/documentation/guides/InstallationUbuntuApache.sh b/documentation/guides/InstallationUbuntuApache.sh\nindex 466ac6f6..420739e3 100644\n--- a/documentation/guides/InstallationUbuntuApache.sh\n+++ b/documentation/guides/InstallationUbuntuApache.sh\n@@ -4,7 +4,7 @@\n # Run with sudo for best results\n #######################################\n SECONDS=0\n-if [[ "$(/usr/bin/whoami)" != "root" ]]; then \n+if [[ "$(/usr/bin/whoami)" != "root" ]]; then\n     echo "This script must be run as root or using sudo.Script aborted."\n     exit 1\n fi\n@@ -104,7 +104,7 @@ echo ""\n \n # finding IP address and compensating for possible EC2 installation\n EC2=`curl --silent --connect-timeout 1 http://169.254.169.254/latest/meta-data/public-hostname`\n-if [[ $EC2 != "" ]]; \n+if [[ $EC2 != "" ]];\n then\n \tIP=`echo $EC2 | sed -rn \'s/ec2-(.*?)\\.compute.*/\\1/p\' | sed \'s/-/./g\'`\n else\ndiff --git a/documentation/guides/InstallationUsingOpenPhotoEC2-AMI.markdown b/documentation/guides/InstallationUsingOpenPhotoEC2-AMI.markdown\nindex d8f2d334..1d11ac1e 100644\n--- a/documentation/guides/InstallationUsingOpenPhotoEC2-AMI.markdown\n+++ b/documentation/guides/InstallationUsingOpenPhotoEC2-AMI.markdown\n@@ -30,7 +30,7 @@ Before setting up your server you\'ll need to make sure you have your cloud accou\n 1. Click back to Instances and wait for new instance to finish starting.\n \n 1. Once started, click on the new instance in the web interface, copy the public DNS information.\n-\t\n+\n ### Launching your OpenPhoto site\n \n Now you\'re ready to launch your OpenPhoto site. Point your browser to your new EC2 host and you\'ll be taken to a setup screen. You\'ll need your cloud account credentiato continue.\n@@ -47,10 +47,10 @@ Once you complete the 3 steps your site will be up and running and you\'ll be red\n Open a terminal or SSH client, using your amazon ec2 ssh public key, ssh into the instance as the ubuntu user using the public DNS information for your instance.\n \n \tssh -i amazon-key.pem ubuntu@new-instance.amazonaws.com\n-\t\n+\n Verify the apache user has write access to the /home/ubuntu/openphoto/src/configs directory.\n \n \tcd /home/ubuntu/openphoto/src/\n \tls -ld ./configs\n-\t\n+\n \tdrwxr-xr-x 3 www-data www-data 4096 2011-08-20 02:37 configs\ndiff --git a/documentation/schemas/Schemas.markdown b/documentation/schemas/Schemas.markdown\nindex b8c4ecc8..c70aa213 100644\n--- a/documentation/schemas/Schemas.markdown\n+++ b/documentation/schemas/Schemas.markdown\n@@ -6,9 +6,9 @@ OpenPhoto\n \n ### What are schemas?\n \n-Schemas are the blueprint for various objects in the OpenPhoto platform. \n-The most logical example is the [Photo][Photo] object which represents a single photo in a user\'s photo collection. \n-Their photo library consists of a collection of [Photo][Photo] objects. \n+Schemas are the blueprint for various objects in the OpenPhoto platform.\n+The most logical example is the [Photo][Photo] object which represents a single photo in a user\'s photo collection.\n+Their photo library consists of a collection of [Photo][Photo] objects.\n Other examples are a [User][User] object and [Action][Action] object.\n \n ----------------------------------------\ndiff --git a/src/configs/openphoto-SUSE-vhost.conf b/src/configs/openphoto-SUSE-vhost.conf\nindex 274ea414..7b66b0c6 100644\n--- a/src/configs/openphoto-SUSE-vhost.conf\n+++ b/src/configs/openphoto-SUSE-vhost.conf\n@@ -6,7 +6,7 @@\n     Order deny,allow\n     Allow from all\n     Options FollowSymLinks\n-    \n+\n     RewriteEngine on\n     RewriteCond %{REQUEST_FILENAME} !-f\n     RewriteCond %{REQUEST_FILENAME} !-d\n@@ -21,7 +21,7 @@\n     AddOutputFilterByType DEFLATE application/x-javascript\n     BrowserMatch ^Mozilla/4 gzip-only-text/html\n     BrowserMatch ^Mozilla/4\\.0[678] no-gzip\n-    BrowserMatch \\bMSIE !no-gzip !gzip-only-text/html \n+    BrowserMatch \\bMSIE !no-gzip !gzip-only-text/html\n   </Directory>\n \n   # 404 Not Found for ini files\n@@ -36,7 +36,7 @@\n   ExpiresByType image/jpg "A604800"\n   ExpiresByType image/jpeg "A604800"\n   ExpiresByType image/png "A604800"\n-  \n+\n   Header set Cache-Control "must-revalidate"\n   FileETag MTime Size\n </VirtualHost>\ndiff --git a/src/configs/openphoto-vhost.conf b/src/configs/openphoto-vhost.conf\nindex 2e041bd0..1c06ad12 100644\n--- a/src/configs/openphoto-vhost.conf\n+++ b/src/configs/openphoto-vhost.conf\n@@ -20,7 +20,7 @@\n     AddOutputFilterByType DEFLATE application/x-javascript\n     BrowserMatch ^Mozilla/4 gzip-only-text/html\n     BrowserMatch ^Mozilla/4\\.0[678] no-gzip\n-    BrowserMatch \\bMSIE !no-gzip !gzip-only-text/html \n+    BrowserMatch \\bMSIE !no-gzip !gzip-only-text/html\n   </Directory>\n \n   # 404 Not Found for ini files\n@@ -35,7 +35,7 @@\n   ExpiresByType image/jpg "A604800"\n   ExpiresByType image/jpeg "A604800"\n   ExpiresByType image/png "A604800"\n-  \n+\n   Header set Cache-Control "must-revalidate"\n   FileETag MTime Size\n </VirtualHost>\ndiff --git a/src/html/assets/javascripts/openphoto-lib-jquery.js b/src/html/assets/javascripts/openphoto-lib-jquery.js\nindex 0b72268d..fce29d77 100644\n--- a/src/html/assets/javascripts/openphoto-lib-jquery.js\n+++ b/src/html/assets/javascripts/openphoto-lib-jquery.js\n@@ -36,7 +36,7 @@\n         var scope = scope || window;\n \n         lib( element ).live(etype, lib.proxy(callback, scope) );\n-        \n+\n         //key events need to use bind, for some reason only gets triggered\n         //when you input in textareas or inputs with jQuery\n         if (etype === "keydown" || etype === "keypress" || etype === "keyup") {\n@@ -58,8 +58,8 @@\n         lib( element ).die( type );\n \n     }\n-    \n-    \n+\n+\n     /**\n     * Makes an ajax post request\n     * @param {string} url to make request to\n@@ -70,9 +70,9 @@\n     * @method makeRequest\n     */\n     OU.makeRequest = function(url, data, callback, format) {\n-    \n+\n     \tlib.post(url, data, callback, format);\n-    \t\n+\n     }\n \n \ndiff --git a/src/html/assets/javascripts/openphoto-util.js b/src/html/assets/javascripts/openphoto-util.js\nindex 383c3850..d05f9896 100644\n--- a/src/html/assets/javascripts/openphoto-util.js\n+++ b/src/html/assets/javascripts/openphoto-util.js\n@@ -14,8 +14,8 @@\n     var PLUGIN_FILE_PREFIX = \'openphoto-lib-\',\n         BROWSER_ID_SRC = \'https://browserid.org/include.js\',\n         log = function(msg) { if(typeof(console) !== \'undefined\') {  console.log(msg); } };\n-         \n-    \n+\n+\n     /**\n     * Class that contains all utility functions for OpenPhoto\n     * We can use a Constructor function in this case since we will\n@@ -26,7 +26,7 @@\n     function Util() {\n \n         /**\n-        * default configuration options \n+        * default configuration options\n         * user can optionally specify an onComplete attribute in the css/js\n         * object which will execute when the assets are loaded.\n         * @type {object}\n@@ -50,7 +50,7 @@\n         * @property eventMap\n         */\n         this.eventMap = {\n-      \n+\n             \'click\': {\n                 \'action-box-click\':\'click:action-box\',\n                 \'action-delete-click\':\'click:action-delete\',\n@@ -71,12 +71,12 @@\n                 \'settings-click\':\'click:settings\',\n                 \'webhook-delete-click\':\'click:webhook-delete\'\n             },\n-            \n+\n             \'keydown\': {\n                 37: \'keydown:browse-previous\',\n                 39: \'keydown:browse-next\'\n             }\n-      \n+\n         };\n \n         /**\n@@ -85,20 +85,20 @@\n         * @property _customEvents\n         */\n         this._customEvents = {};\n-        \n+\n         /**\n         * Count of the number of scripts loaded\n         * @type {Number}\n         * @property _scriptLoadCount\n         */\n         this._scriptLoadCount = 0;\n-        \n+\n         /**\n         * Count of the number of css loaded\n         * @type {Number}\n         * @property _cssLoadCount\n         */\n-        this._cssLoadCount = 0;    \n+        this._cssLoadCount = 0;\n \n         /**\n         * initialization method\n@@ -124,7 +124,7 @@\n \n             // we specify what library type in the .ini file\n             // either jQuery or YUI - and then the user can load\n-            // additional css/js assets by specifying the files in the \n+            // additional css/js assets by specifying the files in the\n             // js config - as specified by the plugin file (that will be user generated).\n \n             //the library is a requirement, by default jQuery will be loaded\n@@ -143,7 +143,7 @@\n         * @method _init\n         */\n         this._init = function() {\n-  \n+\n             log(\'[Util] _init:\')\n \n             var js = this.config.js.assets,\n@@ -151,7 +151,7 @@\n                 i,\n                 length;\n \n-            //attach events      \n+            //attach events\n             this.attachEvent( \'body\', \'click\', this.onviewevent, this);\n             this.attachEvent( \'body\', \'keydown\', this.onkeydownevent, this);\n \n@@ -162,10 +162,10 @@\n \n             //load additional css in order specified\n             for(i=0, j=css.length; i<j; i++) {\n-                this.loadCss( css[i], this._handleCssLoad, this ); \n+                this.loadCss( css[i], this._handleCssLoad, this );\n             }\n-  \n-        };  \n+\n+        };\n \n         /**\n         * handles events - delegates based on className\n@@ -182,19 +182,19 @@\n                 length = classes.length,\n                 map = this.eventMap[e.type],\n                 cls;\n-                \n+\n             while (length--) {\n                 cls = classes[length];\n                 if (map[cls]) {\n                     //do not prevent the default action, let the callback\n                     //function do it if it wants\n-                    this.fire( map[cls], e);    \n-                }      \n-            }    \n-  \n-  \n+                    this.fire( map[cls], e);\n+                }\n+            }\n+\n+\n         };\n-        \n+\n         /**\n         * handles keydown events\n         * @param {Event} e\n@@ -203,7 +203,7 @@\n         */\n         this.onkeydownevent = function(e) {\n           log(\'[Util] keydownevent: \' + e.target);\n-          \n+\n           var targ = e.target || e.srcElement,\n             classes = targ.className.split(" "),\n             length = classes.length,\n@@ -211,38 +211,38 @@\n             nodeName = targ.nodeName.toLowerCase(),\n             keyCode = e.keyCode,\n             cls;\n-            \n+\n           if (nodeName === "textarea" || nodeName === "input") {\n-          \n+\n             //i don\'t think there is a case where the user needs to know\n-            //if the user is inputing text, but just in case, lets fire \n+            //if the user is inputing text, but just in case, lets fire\n             //a custom event on user input\n             this.fire( \'keydown:user-input\', e);\n-          \n+\n           } else {\n-            \n+\n             //the event map for key press can be two dimensional, it can be\n             //keycode, or className then keyCode, if keyCode, fire the custom event\n             if (map[keyCode]) {\n               this.fire( map[keyCode], e);\n             }\n-                        \n+\n             //both className and keycode\n             while (length--) {\n                   cls = classes[length];\n                   if (map[cls] && map[cls][keyCode]) {\n                       //do not prevent the default action, let the callback\n                       //function do it if it wants\n-                      this.fire( map[cls][keyCode], e);    \n-                  }      \n+                      this.fire( map[cls][keyCode], e);\n+                  }\n               }\n-          \n-          \n+\n+\n           }\n-          \n-        \n+\n+\n         };\n-    \n+\n         /* -------------------------------------------------\n         *         Utilities\n         * ------------------------------------------------- */\n@@ -264,9 +264,9 @@\n             //load the script and attach the event handlers onload\n             this.loadScript(url, this._init, this);\n             this.loadScript(BROWSER_ID_SRC);\n-          \n+\n         };\n-    \n+\n         /**\n         * Shallow merge of all objects passed into it in order of the objects passed in\n         * this is just needed to merge the config, but will probably be overwritten by\n@@ -295,7 +295,7 @@\n \n             return merged;\n \n-        };    \n+        };\n \n         /**\n         * Utility function to dynamically load a script\n@@ -306,7 +306,7 @@\n         * @method loadScript\n         */\n         this.loadScript = function(url, fn, scope) {\n-  \n+\n             log(\'[Util] loadScript\');\n \n             var head = document.getElementsByTagName(\'head\')[0],\n@@ -334,7 +334,7 @@\n             }\n \n             head.appendChild(script);\n-  \n+\n         };\n \n \n@@ -347,7 +347,7 @@\n         * @method loadScript\n         */\n         this.loadCss = function(url, fn, scope) {\n-  \n+\n             log(\'[Util] loadCss\');\n \n             var head = document.getElementsByTagName(\'head\')[0],\n@@ -376,9 +376,9 @@\n             }\n \n             head.appendChild(link);\n-  \n+\n         };\n-        \n+\n         /**\n         * The user can specify a callback to execute when all of the javascript assets\n         * have loaded.  This helper method keeps track of the number of javascript assets\n@@ -387,15 +387,15 @@\n         * @method _handleScriptLoad\n         */\n         this._handleScriptLoad = function() {\n-            \n+\n             this._scriptLoadCount++;\n-            \n+\n             if ( (this._scriptLoadCount === this.config.js.assets.length) && (typeof(this.config.js.onComplete) !== \'undefined\')) {\n                 this.config.js.onComplete();\n-            }          \n-            \n+            }\n+\n         }\n-        \n+\n         /**\n         * The user can specify a callback to execute when all of the css assets\n         * have loaded.  This helper method keeps track of the number of css assets\n@@ -404,13 +404,13 @@\n         * @method _handleCssLoad\n         */\n         this._handleCssLoad = function() {\n-            \n+\n             this._cssLoadCount++;\n-            \n+\n             if ( (this._cssLoadCount === this.config.css.assets.length) && (typeof(this.config.css.onComplete) !== \'undefined\')) {\n                 this.config.css.onComplete();\n-            }            \n-            \n+            }\n+\n         }\n \n         /**\n@@ -419,7 +419,7 @@\n         * @method detectLibrary\n         */\n         this.detectLibrary = function() {\n-  \n+\n             //very simple for now, but we can extend it later\n             var lib = \'\';\n \n@@ -438,16 +438,16 @@\n             }\n \n             return lib;\n-  \n-        };  \n+\n+        };\n \n \n         /* -------------------------------------------------\n         *         Custom Events\n         * ------------------------------------------------- */\n-    \n+\n         /**\n-        * Subscribe to a custom event - the callback will be executed when the custom event is fired \n+        * Subscribe to a custom event - the callback will be executed when the custom event is fired\n         * @param {string} eventName - the name of the custom event to subscribe to\n         * @param {Function} callback - the callback function that will be executed when the event is fired\n         * @param {Object} scope - the scope of the callback function (what this will refer to)\n@@ -508,7 +508,7 @@\n                     }\n                 }\n             }\n-  \n+\n         };\n \n         /**\n@@ -532,8 +532,8 @@\n             }\n \n         };\n-        \n-        \n+\n+\n         /**\n         * Object containing everything needed to upload photos\n         *\n@@ -562,7 +562,7 @@\n                 returnSizes : "25x25xCR",\n                 crumb : null\n             },\n-            \n+\n             parent : this,\n             droppedFiles : {},\n             simultaneousUploads : 0,\n@@ -570,8 +570,8 @@\n             uploadQueue : [],\n             uploadQueueIndex : 0,\n             xhrs : [],\n-            \n-            \n+\n+\n             /**\n             * initialize upload area and functions\n             * @param {object} options - object defining options to override defaults\n@@ -588,7 +588,7 @@\n                     this._fallbackUploader();\n                 }\n             },\n-            \n+\n             /**\n             * enable or disable duplicate photo name checking\n             * @param {bool} state should duplicates be allowed?\n@@ -602,10 +602,10 @@\n                     this.options.allowDuplicates = false;\n                 }\n             },\n-            \n+\n             _uploadEventHandlers : function() {\n                 /*\n-                    TODO prevent page from leaving with confirmation if user drops photo in wrong \n+                    TODO prevent page from leaving with confirmation if user drops photo in wrong\n                     place or hits key to navigate before all uploads are done\n                 */\n                 var that = this;\n@@ -614,7 +614,7 @@\n                 that._addListener(that.dropZone, \'dragleave\', that._handleDragLeave, that);\n                 that._addListener(that.dropZone, \'drop\', that._handleFileDrop, that);\n             },\n-            \n+\n             /**\n             * wrapper for addEventListener to enable passing along the \'that\' context\n             * @param target dom element to attach to\n@@ -630,30 +630,30 @@\n                     callback(e,context);\n                 }, false);\n             },\n-            \n+\n             _handleDragEnter : function(e, that) {\n                 e.stopPropagation();\n                 e.preventDefault();\n                 that.options.dragEnterCallback()\n             },\n-            \n+\n             _handleDragLeave : function(e, that) {\n                 e.stopPropagation();\n                 e.preventDefault();\n                 that.options.dragLeaveCallback();\n             },\n-            \n+\n             /**\n             * when user\'s mouse moves over dropzone while draggin files\n             *\n-            * if we don\'t prevent default, dropping the file \n+            * if we don\'t prevent default, dropping the file\n             * wil cause the browser to redirect to the file location\n             **/\n             _handleDragOver : function(e, that) {\n                 e.stopPropagation();\n                 e.preventDefault();\n             },\n-            \n+\n             _handleFileDrop : function(e, that) {\n                 e.stopPropagation();\n                 e.preventDefault();\n@@ -661,7 +661,7 @@\n                 var files = e.dataTransfer.files;\n                 that._checkForDuplicates(files);\n             },\n-            \n+\n             _checkForDuplicates : function(files) {\n                 var that = this;\n                 if (!that.allowDuplicates) {\n@@ -678,7 +678,7 @@\n                 }\n                 that._validateIsImage(files);\n             },\n-            \n+\n             _validateIsImage : function(files) {\n                 var that = this;\n                 /*\n@@ -687,7 +687,7 @@\n                 // that.options.notImageCallback();\n                 that._indexAndStack(files);\n             },\n-            \n+\n             /**\n             * each file receives a reference number so that it can be correlated to\n             * its coresponding UI representation\n@@ -700,8 +700,8 @@\n                 }\n                 that.options.pushToUICallback(files);\n             },\n-            \n-            \n+\n+\n             // theme must call this to start uploading files\n             kickOffUploads : function() {\n                 var that = this;\n@@ -721,14 +721,14 @@\n                     }\n                 }\n             },\n-            \n+\n             _ajaxToServer : function(file) {\n                 var that = this;\n-                \n+\n                 that.simultaneousUploads++;\n                 var xhr = new XMLHttpRequest();\n                 that.xhrs.push(xhr);\n-                \n+\n                 var formData = new FormData();\n                 formData.append("crumb",that.options.crumb);\n                 formData.append("returnSizes",that.options.returnSizes);\n@@ -736,8 +736,8 @@\n                 formData.append("license", that.options.photoLicense(file.queueIndex));\n                 formData.append("tags", that.options.photoTags(file.queueIndex));\n                 formData.append("permission", that.options.permission(file.queueIndex));\n-                xhr.open("POST", that.options.uploadPath, true);  \n-                \n+                xhr.open("POST", that.options.uploadPath, true);\n+\n                 xhr.onload = function(e) {\n                     that.simultaneousUploads--;\n                     // tell theme we finished\n@@ -751,10 +751,10 @@\n                         that.options.uploadProgressCallback(file.queueIndex, progress);\n                     }\n                 };\n-                \n+\n                 xhr.send(formData);\n             },\n-            \n+\n             _fallbackUploader : function() {\n                 /*\n                     TODO actually fallback to other uploader\ndiff --git a/src/html/assets/themes/default/javascripts/openphoto-theme-mobile.js b/src/html/assets/themes/default/javascripts/openphoto-theme-mobile.js\nindex 77d91144..86a26081 100644\n--- a/src/html/assets/themes/default/javascripts/openphoto-theme-mobile.js\n+++ b/src/html/assets/themes/default/javascripts/openphoto-theme-mobile.js\n@@ -7,12 +7,12 @@ var opTheme = (function() {\n     init: {\n       attach: function(PhotoSwipe) {\n         $(\'div.gallery-page\').live(\'pageshow\', function(e){\n-          var \n+          var\n             currentPage = $(e.target),\n             photoSwipeInstanceId = parseInt(Math.random()*10000),\n             photoSwipeInstance = PhotoSwipe.getInstance(photoSwipeInstanceId)\n             options = {};\n-          \n+\n           if ($("ul.gallery a").length > 0 && (typeof photoSwipeInstance === "undefined" || photoSwipeInstance === null)) {\n             photoSwipeInstance = $("ul.gallery a", e.target).photoSwipe(options, photoSwipeInstanceId);\n           }\ndiff --git a/src/html/assets/themes/default/javascripts/openphoto-theme.js b/src/html/assets/themes/default/javascripts/openphoto-theme.js\nindex 073a9a25..c54d0525 100644\n--- a/src/html/assets/themes/default/javascripts/openphoto-theme.js\n+++ b/src/html/assets/themes/default/javascripts/openphoto-theme.js\n@@ -10,22 +10,22 @@ var opTheme = (function() {\n         log("keyboard!!!!");\n       },\n       actionDelete: function(ev) {\n-      \n+\n         ev.preventDefault();\n-      \n+\n         var el = $(ev.target),\n           \turl = el.attr(\'href\')+\'.json\'\n             id = el.attr(\'data-id\');\n-      \n+\n         OP.Util.makeRequest(url, el.parent().serializeArray(), function(response) {\n           if(response.code === 200)\n             $(".action-container-"+id).hide(\'medium\', function(){ $(this).remove(); });\n           else\n             opTheme.message.error(\'Could not delete the photo.\');\n         }, \'json\');\n-        \n+\n         return false;\n-        \n+\n       },\n       commentJump: function(ev) {\n         ev.preventDefault();\n@@ -75,11 +75,11 @@ var opTheme = (function() {\n         });\n       },\n       photoDelete: function(ev) {\n-      \n+\n         ev.preventDefault();\n         var el = $(ev.target),\n           \turl = el.parent().attr(\'action\')+\'.json\';\n-      \n+\n         OP.Util.makeRequest(url, el.parent().serializeArray(), function(response) {\n           if(response.code === 200) {\n             el.html(\'This photo has been deleted\');\n@@ -315,7 +315,7 @@ var opTheme = (function() {\n         }\n       }\n     },\n-    \n+\n     upload: {\n       init: function() {\n         var that = this; // that references upload\n@@ -338,7 +338,7 @@ var opTheme = (function() {\n           that.licenseChange();\n         }\n       },\n-      \n+\n       options : {\n         simultaneousUploadLimit : 3,\n         frameId : "uploader-frame",\n@@ -347,7 +347,7 @@ var opTheme = (function() {\n         returnSizes : "50x50xCR",\n         allowDuplicates : false\n       },\n-      \n+\n       licenseChange : function() {\n         $("#uploader-frame .license").bind("change", function() {\n           if ($(this).val() == "_custom_") {\n@@ -359,33 +359,33 @@ var opTheme = (function() {\n           }\n         });\n       },\n-      \n+\n       /**\n       * !! REMINDER !!\n-      * These functions are going to be called from within the \n-      * opTheme.upload.options object so \'this\' points back to \n+      * These functions are going to be called from within the\n+      * opTheme.upload.options object so \'this\' points back to\n       * the options object\n       **/\n       dragEnter : function() {\n         this.$dropZone.removeClass("waiting active").addClass("hover");\n       },\n-      \n+\n       dragLeave : function() {\n         this.$dropZone.removeClass("hover").addClass("active");\n       },\n-      \n+\n       dragDrop : function() {\n         this.$dropZone.removeClass("hover").addClass("active");\n       },\n-      \n+\n       duplicate : function() {\n         opTheme.message.error("duplicate image");\n       },\n-      \n+\n       notImage : function() {\n         opTheme.message.error("not an image file");\n       },\n-      \n+\n       pushToUI : function(files) {\n         // get current tags and license data to apply to each photo\n         var tags = $("#uploader-frame .tags").val();\n@@ -402,17 +402,17 @@ var opTheme = (function() {\n         this.$dropZone.append(html.join(""));\n         OP.Util.upload.kickOffUploads();\n       },\n-      \n+\n       uploadStart : function(queueIndex) {\n         $("#file-"+queueIndex).removeClass("waiting").addClass("uploading");\n       },\n-      \n+\n       uploadProgress : function(queueIndex, percent) {\n         $("#file-"+queueIndex+" .progress").animate({\n           "width":percent+"%"\n         }, 500);\n       },\n-      \n+\n       uploadFinished : function(queueIndex, status, response) {\n         var thisClass = response.code == 202 ? \'finished\' : \'error\';\n         $("#file-"+queueIndex+" .progress").addClass(thisClass);\n@@ -420,15 +420,15 @@ var opTheme = (function() {\n         if(response.code == 202)\n           $("#file-"+queueIndex).append("<img class=\'thumb\' src=\'"+response.result.path50x50xCR+"\'/>");\n       },\n-      \n+\n       permission : function(queueIndex) {\n         return $("#file-"+queueIndex).attr("permission");\n       },\n-      \n+\n       photoLicense : function(queueIndex) {\n         return $("#file-"+queueIndex).attr("license");\n       },\n-      \n+\n       photoTags : function(queueIndex) {\n         return $("#file-"+queueIndex).attr("tags");\n       }\n@@ -457,7 +457,7 @@ var opTheme = (function() {\n         $(\'form.validate\').each(opTheme.formHandlers.init);\n       }\n     },\n-    \n+\n     message: {\n       close: function() {\n         if(timeoutId != undefined) {\ndiff --git a/src/html/assets/themes/default/stylesheets/styles.css b/src/html/assets/themes/default/stylesheets/styles.css\nindex 9e981025..d36e6419 100644\n--- a/src/html/assets/themes/default/stylesheets/styles.css\n+++ b/src/html/assets/themes/default/stylesheets/styles.css\n@@ -44,8 +44,8 @@ header>div{\n   height:48px;\n   border-bottom:solid 1px #fff;\n }\n-header ul{ \n-  list-style-type:none; \n+header ul{\n+  list-style-type:none;\n   display: inline-block;\n   position:relative;\n   left:200px;\n@@ -74,7 +74,7 @@ header ul li a{\n }\n div#searchbar{\n   display:none;\n-  position:relative; \n+  position:relative;\n   width:226px;\n   top:1px;\n   padding:10px;\n@@ -110,12 +110,12 @@ div#photos ul.grid>li {\n   width:200px;\n   height:225px;\n   padding: 25px 40px 25px 0;\n-} \n+}\n div#photos ul.grid>li>a>img{\n   -moz-box-shadow: 2px 2px 2px #888;\n   -webkit-box-shadow: 2px 2px 2px #888;\n }\n-div#photos ul.grid ul.options { \n+div#photos ul.grid ul.options {\n   margin:0;\n   padding:0;\n   list-style:none;\ndiff --git a/src/html/assets/themes/default/stylesheets/upload.css b/src/html/assets/themes/default/stylesheets/upload.css\nindex 062fdd37..48cf92c3 100644\n--- a/src/html/assets/themes/default/stylesheets/upload.css\n+++ b/src/html/assets/themes/default/stylesheets/upload.css\n@@ -52,7 +52,7 @@ div#upload ul#upload-queue div.progress{\n   -moz-border-radius-bottomright: 4px;\n   -moz-border-radius-bottomleft: 4px;\n   -webkit-border-radius: 0px 0px 4px 4px;\n-  border-radius: 0px 0px 4px 4px; \n+  border-radius: 0px 0px 4px 4px;\n \n }\n div#upload ul#upload-queue div.progress > div{\n@@ -61,7 +61,7 @@ div#upload ul#upload-queue div.progress > div{\n   -moz-border-radius-bottomright: 4px;\n   -moz-border-radius-bottomleft: 4px;\n   -webkit-border-radius: 0px 0px 4px 4px;\n-  border-radius: 0px 0px 4px 4px; \n+  border-radius: 0px 0px 4px 4px;\n   background-image:url("../images/progress.gif");\n }\n div#upload ul#upload-queue div.progress > div.complete{\n@@ -103,9 +103,9 @@ div#upload ul#upload-queue div.progress > div.complete{\n #drop-zone .photo { width: 100%; position: relative; height: 32px; z-index: 5; padding: 17px 0 6px 0;}\n #drop-zone .photo .name { margin-left: 60px; }\n #drop-zone .photo .size { float: right; margin-right: 5px; }\n-#drop-zone .photo > span.progress { \n+#drop-zone .photo > span.progress {\n   z-index: -1;\n-  display: block; \n+  display: block;\n   height: 100%;\n   background-color: #e5e88b;\n   background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0, #e5e88b), color-stop(1, #f0f2ac));\n@@ -119,7 +119,7 @@ div#upload ul#upload-queue div.progress > div.complete{\n   top: 0px;\n   overflow: hidden;\n }\n-#drop-zone .photo > span.progress.finished { \n+#drop-zone .photo > span.progress.finished {\n   background-color: rgb(43,194,83);\n   background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0, rgb(43,194,83)), color-stop(1, rgb(84,240,84)) );\n   background-image: -webkit-linear-gradient( center bottom, rgb(43,194,83) 37%, rgb(84,240,84) 69% );\n@@ -127,7 +127,7 @@ div#upload ul#upload-queue div.progress > div.complete{\n   background-image: -ms-linear-gradient( center bottom, rgb(43,194,83) 37%, rgb(84,240,84) 69% );\n   background-image: -o-linear-gradient( center bottom, rgb(43,194,83) 37%, rgb(84,240,84) 69% );\n }\n-#drop-zone .photo > span.progress.error { \n+#drop-zone .photo > span.progress.error {\n   background-color: rgb(214,105,163);\n   background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0, rgb(214,105,163)), color-stop(1, rgb(235,113,178)) );\n   background-image: -webkit-linear-gradient( center bottom, rgb(214,105,163) 37%, rgb(235,113,178) 69% );\ndiff --git a/src/html/assets/themes/default/templates/front-mobile.php b/src/html/assets/themes/default/templates/front-mobile.php\nindex 37e17b14..6ce22d33 100644\n--- a/src/html/assets/themes/default/templates/front-mobile.php\n+++ b/src/html/assets/themes/default/templates/front-mobile.php\n@@ -1,20 +1,20 @@\n <div data-role="page" data-add-back-btn="true" id="Gallery1" class="gallery-page" data-theme="c">\n \t<div data-role="header" class="photoheader" data-theme="c"></div>\n \n-\t<div data-role="content">\t\n+\t<div data-role="content">\n     <form id="search-photo-form" action="/photos/list" method="get">\n             <div data-role="fieldcontain" class="center-wrapper">\n                 <input type="search" name="tags" id="tags" placeholder="search your photos ..."/>\n             </div>\n-        </form>\t\t\n+        </form>\n     <ul data-role="listview" data-inset="true">\n         <li><a href="/photos/list"><img\n         src="<?php getTheme()->asset(\'image\', \'header-navigation-photos.png\'); ?>" alt="my photos"\n-                        class="ui-li-icon">Photos</a></li> \n+                        class="ui-li-icon">Photos</a></li>\n         <li><a href="/tags/list"><img\n         src="<?php getTheme()->asset(\'image\', \'header-navigation-tags.png\'); ?>" alt="tags"\n                         class="ui-li-icon">Tags</a></li>\n-    </ul> \n+    </ul>\n \t</div>\n \t<div data-role="footer" data-theme="c">\n     <h4>The OpenPhoto Project &#169; <?php echo date(\'Y\'); ?></h4>\ndiff --git a/src/html/assets/themes/default/templates/photo-details-mobile.php b/src/html/assets/themes/default/templates/photo-details-mobile.php\nindex 5dae03f1..62a2655e 100644\n--- a/src/html/assets/themes/default/templates/photo-details-mobile.php\n+++ b/src/html/assets/themes/default/templates/photo-details-mobile.php\n@@ -2,7 +2,7 @@\n   <div data-role="header" class="photoheader" data-theme="c">\n     <a href="/" data-icon="home" class="ui-btn-right" rel="external">Home</a>\n   </div>\n-\t<div data-role="content">\t\n+\t<div data-role="content">\n     <div class="photo-details">\n       <div class="image-pagination">\n         <?php if(!empty($photo[\'previous\'])) { ?>\n@@ -53,9 +53,9 @@\n           </ul>\n         </li>\n       </ul>\n-    </div> \n+    </div>\n \t</div>\n-\t\n+\n \t<div data-role="footer" data-theme="c">\n     <h4>The OpenPhoto Project &#169; <?php echo date(\'Y\'); ?></h4>\n \t</div>\ndiff --git a/src/html/assets/themes/default/templates/photos-mobile.php b/src/html/assets/themes/default/templates/photos-mobile.php\nindex 0e8afdc1..a9ee3f2c 100644\n--- a/src/html/assets/themes/default/templates/photos-mobile.php\n+++ b/src/html/assets/themes/default/templates/photos-mobile.php\n@@ -2,7 +2,7 @@\n   <div data-role="header" class="photoheader" data-theme="c">\n     <a href="/" data-icon="home" class="ui-btn-right" rel="external">Home</a>\n   </div>\n-\t<div data-role="content">\t\n+\t<div data-role="content">\n     <?php if(!empty($photos)) { ?>\n       <ul class="gallery">\n         <?php foreach($photos as $photo) { ?>\n@@ -14,7 +14,7 @@\n       <h2>Sorry, no photos to see.</h2>\n     <?php } ?>\n \t</div>\n-\t\n+\n \t<div data-role="footer" data-theme="c">\n     <h4>The OpenPhoto Project &#169; <?php echo date(\'Y\'); ?></h4>\n \t</div>\ndiff --git a/src/html/assets/themes/default/templates/tags-mobile.php b/src/html/assets/themes/default/templates/tags-mobile.php\nindex e226c750..3b597b8e 100644\n--- a/src/html/assets/themes/default/templates/tags-mobile.php\n+++ b/src/html/assets/themes/default/templates/tags-mobile.php\n@@ -2,7 +2,7 @@\n   <div data-role="header" class="photoheader" data-theme="c">\n     <a href="/" data-icon="home" class="ui-btn-right" rel="external">Home</a>\n   </div>\n-\t<div data-role="content">\t\n+\t<div data-role="content">\n     <?php if(empty($tags)) { ?>\n       Sorry, no photos have been tagged.\n     <?php } else { ?>\ndiff --git a/src/html/assets/themes/default/templates/template.php b/src/html/assets/themes/default/templates/template.php\nindex 79213c78..32457ba9 100644\n--- a/src/html/assets/themes/default/templates/template.php\n+++ b/src/html/assets/themes/default/templates/template.php\n@@ -55,8 +55,8 @@\n       js: {\n         assets: [\n           \'<?php getTheme()->asset(\'javascript\', \'jquery.scrollTo-1.4.2-min.js\'); ?>\',\n-          \'<?php getTheme()->asset(\'javascript\', \'jquery.fileupload.min.js\'); ?>\', \n-          \'<?php getTheme()->asset(\'javascript\', \'jquery.cycle.min.js \'); ?>\', \n+          \'<?php getTheme()->asset(\'javascript\', \'jquery.fileupload.min.js\'); ?>\',\n+          \'<?php getTheme()->asset(\'javascript\', \'jquery.cycle.min.js \'); ?>\',\n           \'<?php getTheme()->asset(\'javascript\', \'openphoto-theme.js\'); ?>\'\n         ],\n         onComplete: function(){ opTheme.init.attach(); }\ndiff --git a/src/libraries/adapters/DatabaseMySql.php b/src/libraries/adapters/DatabaseMySql.php\nindex 607d4957..405b5a01 100644\n--- a/src/libraries/adapters/DatabaseMySql.php\n+++ b/src/libraries/adapters/DatabaseMySql.php\n@@ -23,7 +23,7 @@ class DatabaseMySql implements DatabaseInterface\n   public function __construct()\n   {\n     $mysql = getConfig()->get(\'mysql\');\n-    EpiDatabase::employ(\'mysql\', $mysql->mySqlDb, \n+    EpiDatabase::employ(\'mysql\', $mysql->mySqlDb,\n                         $mysql->mySqlHost, $mysql->mySqlUser, Utility::decrypt($mysql->mySqlPassword));\n     foreach($mysql as $key => $value) {\n       $this->{$key} = $value;\n@@ -189,7 +189,7 @@ class DatabaseMySql implements DatabaseInterface\n     * Retrieve group from the database specified by $id\n     *\n     * @param string $id id of the group to return\n-    * @return mixed Array on success, FALSE on failure \n+    * @return mixed Array on success, FALSE on failure\n     */\n   public function getGroup($id = null)\n   {\n@@ -206,7 +206,7 @@ class DatabaseMySql implements DatabaseInterface\n     * Retrieve groups from the database optionally filter by member (email)\n     *\n     * @param string $email email address to filter by\n-    * @return mixed Array on success, NULL on empty, FALSE on failure \n+    * @return mixed Array on success, NULL on empty, FALSE on failure\n     */\n   public function getGroups($email = null)\n   {\n@@ -900,9 +900,9 @@ class DatabaseMySql implements DatabaseInterface\n     $photo[\'appId\'] = getConfig()->get(\'application\')->appId;\n \n     $versions = $this->getPhotoVersions($photo[\'id\']);\n-    if($versions && !empty($versions)) \n+    if($versions && !empty($versions))\n     {\n-      foreach($versions as $version) \n+      foreach($versions as $version)\n       {\n         $photo[$version[\'key\']] = $version[\'path\'];\n       }\n@@ -1054,7 +1054,7 @@ class DatabaseMySql implements DatabaseInterface\n     {\n       $params[\'::bindings\'] = $bindings;\n     }\n-    return $params;    \n+    return $params;\n   }\n   /** Prepare credential to store in the database\n    */\n@@ -1105,7 +1105,7 @@ class DatabaseMySql implements DatabaseInterface\n \n   /**\n    * Check the Db Version.\n-   * \n+   *\n    * This shouldn\'t fail unless you don\'t have database access\n    * But if the DB is empty (ie don\'t have the tables), it returns 0\n    * @return the numeric version. 0 means no DB\n@@ -1134,7 +1134,7 @@ class DatabaseMySql implements DatabaseInterface\n   {\n     if($version < 1)\n       return false;\n-    switch($version) {      \t\n+    switch($version) {\n     case 1:\n       // after version 1 we added credential\n       //\ndiff --git a/src/libraries/adapters/DatabaseSimpleDb.php b/src/libraries/adapters/DatabaseSimpleDb.php\nindex 7be0aa70..c6d33a06 100644\n--- a/src/libraries/adapters/DatabaseSimpleDb.php\n+++ b/src/libraries/adapters/DatabaseSimpleDb.php\n@@ -11,7 +11,7 @@ class DatabaseSimpleDb implements DatabaseInterface\n     * Member variables holding the names to the SimpleDb domains needed and the database object itself.\n     * @access private\n     */\n-  private $db, $domainAction, $domainCredential, $domainPhoto, \n+  private $db, $domainAction, $domainCredential, $domainPhoto,\n     $domainTag, $domainUser, $domainWebhook, $errors = array();\n \n   /**\n@@ -213,7 +213,7 @@ class DatabaseSimpleDb implements DatabaseInterface\n     * Retrieve group from the database specified by $id\n     *\n     * @param string $id id of the group to return\n-    * @return mixed Array on success, FALSE on failure \n+    * @return mixed Array on success, FALSE on failure\n     */\n   public function getGroup($id = null)\n   {\n@@ -229,7 +229,7 @@ class DatabaseSimpleDb implements DatabaseInterface\n     * Retrieve groups from the database optionally filter by member (email)\n     *\n     * @param string $email email address to filter by\n-    * @return mixed Array on success, NULL on empty, FALSE on failure \n+    * @return mixed Array on success, NULL on empty, FALSE on failure\n     */\n   public function getGroups($email = null)\n   {\n@@ -450,7 +450,7 @@ class DatabaseSimpleDb implements DatabaseInterface\n     $this->logErrors($res);\n     if(!$res->isOK())\n       return false;\n-    \n+\n \n     if(isset($res->body->SelectResult))\n     {\n@@ -480,7 +480,7 @@ class DatabaseSimpleDb implements DatabaseInterface\n     if(count($domains) == 7)\n       return true;\n \n-    $domainsToCreate = array($this->domainAction, $this->domainCredential, $this->domainGroup, \n+    $domainsToCreate = array($this->domainAction, $this->domainCredential, $this->domainGroup,\n       $this->domainPhoto, $this->domainTag, $this->domainUser, $this->domainWebhook);\n \n     $queue = new CFBatchRequest();\ndiff --git a/src/libraries/adapters/FileSystemDropboxBase.php b/src/libraries/adapters/FileSystemDropboxBase.php\nindex 65db00dd..58c51f87 100644\n--- a/src/libraries/adapters/FileSystemDropboxBase.php\n+++ b/src/libraries/adapters/FileSystemDropboxBase.php\n@@ -6,7 +6,7 @@\n  * @author Hub Figuiere <hub@figuiere.net>\n  * @author Jaisen Mathai <jaisen@jmathai.com>\n  */\n-class FileSystemDropboxBase \n+class FileSystemDropboxBase\n {\n   private $parent;\n   public function __construct($parent)\ndiff --git a/src/libraries/controllers/ApiController.php b/src/libraries/controllers/ApiController.php\nindex 9b0c63bc..8385a7e2 100644\n--- a/src/libraries/controllers/ApiController.php\n+++ b/src/libraries/controllers/ApiController.php\n@@ -9,7 +9,7 @@ class ApiController extends BaseController\n   /**\n     * A diagnostics endpoint used to verify backends are working.\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function diagnostics()\n   {\n@@ -32,7 +32,7 @@ class ApiController extends BaseController\n   /**\n     * A diagnostics endpoint used to verify calls are working.\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function hello()\n   {\ndiff --git a/src/libraries/controllers/ApiGroupController.php b/src/libraries/controllers/ApiGroupController.php\nindex 48232496..868ae730 100644\n--- a/src/libraries/controllers/ApiGroupController.php\n+++ b/src/libraries/controllers/ApiGroupController.php\n@@ -1,7 +1,7 @@\n <?php\n /**\n   * Group controller for API endpoints.\n-  * \n+  *\n   * @author Jaisen Mathai <jaisen@jmathai.com>\n  */\n class ApiGroupController extends BaseController\n@@ -10,7 +10,7 @@ class ApiGroupController extends BaseController\n     * Create a new group\n     * Returns the newly created group or false as the response data\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function create()\n   {\n@@ -31,7 +31,7 @@ class ApiGroupController extends BaseController\n   /**\n     * Delete a group\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function delete($id)\n   {\n@@ -48,7 +48,7 @@ class ApiGroupController extends BaseController\n     * Update an existing group\n     * Returns the newly created group or false as the response data\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function update($id)\n   {\n@@ -70,7 +70,7 @@ class ApiGroupController extends BaseController\n   /**\n     * Get the owner\'s groups\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function list_()\n   {\n@@ -87,7 +87,7 @@ class ApiGroupController extends BaseController\n     * Get the owner\'s group as specified by the groupId\n     *\n     * @param string $id The id of the group\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function view($id)\n   {\ndiff --git a/src/libraries/controllers/ApiOAuthController.php b/src/libraries/controllers/ApiOAuthController.php\nindex 0053c440..f739feed 100644\n--- a/src/libraries/controllers/ApiOAuthController.php\n+++ b/src/libraries/controllers/ApiOAuthController.php\n@@ -1,7 +1,7 @@\n <?php\n /**\n   * OAuth controller for API endpoints.\n-  * \n+  *\n   * @author Jaisen Mathai <jaisen@jmathai.com>\n  */\n class ApiOAuthController extends BaseController\ndiff --git a/src/libraries/controllers/ApiPhotoController.php b/src/libraries/controllers/ApiPhotoController.php\nindex 91d924cd..4a73326b 100644\n--- a/src/libraries/controllers/ApiPhotoController.php\n+++ b/src/libraries/controllers/ApiPhotoController.php\n@@ -427,7 +427,7 @@ class ApiPhotoController extends BaseController\n       $filters[\'permission\'] = $permission;\n     elseif($permission == -1)\n       $filters[\'groups\'] = $groupIds;\n-    \n+\n     return array(\'filters\' => $filters, \'pageSize\' => $pageSize, \'protocol\' => $protocol, \'page\' => $page);\n   }\n }\ndiff --git a/src/libraries/controllers/ApiTagController.php b/src/libraries/controllers/ApiTagController.php\nindex 21035282..84e9c40e 100644\n--- a/src/libraries/controllers/ApiTagController.php\n+++ b/src/libraries/controllers/ApiTagController.php\n@@ -10,7 +10,7 @@ class ApiTagController extends BaseController\n   /**\n     * Delete a tag in the tag database.\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function delete($tag)\n   {\n@@ -25,7 +25,7 @@ class ApiTagController extends BaseController\n   /**\n     * Create a tag in the tag database.\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function create()\n   {\n@@ -38,7 +38,7 @@ class ApiTagController extends BaseController\n   /**\n     * Update a tag in the tag database.\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function update($tag)\n   {\n@@ -60,7 +60,7 @@ class ApiTagController extends BaseController\n   /**\n     * Return all tags.\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function view()\n   {\ndiff --git a/src/libraries/controllers/ApiUserController.php b/src/libraries/controllers/ApiUserController.php\nindex 74eed461..f6e4f7de 100644\n--- a/src/libraries/controllers/ApiUserController.php\n+++ b/src/libraries/controllers/ApiUserController.php\n@@ -1,7 +1,7 @@\n <?php\n /**\n   * User controller for API endpoints.\n-  * \n+  *\n   * @author Jaisen Mathai <jaisen@jmathai.com>\n  */\n class ApiUserController extends BaseController\n@@ -9,7 +9,7 @@ class ApiUserController extends BaseController\n   /**\n     * Log a user in via BrowserID\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function login()\n   {\n@@ -23,7 +23,7 @@ class ApiUserController extends BaseController\n   /**\n     * Log a user in via mobilePassphrase\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function loginMobile()\n   {\n@@ -41,7 +41,7 @@ class ApiUserController extends BaseController\n   /**\n     * Log a user out.\n     *\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function logout()\n   {\n@@ -53,7 +53,7 @@ class ApiUserController extends BaseController\n     * Update a group\n     *\n     * @param string $id id of the group to update\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function postGroup($id = null)\n   {\ndiff --git a/src/libraries/controllers/ApiWebhookController.php b/src/libraries/controllers/ApiWebhookController.php\nindex 6e312539..ab04cf22 100644\n--- a/src/libraries/controllers/ApiWebhookController.php\n+++ b/src/libraries/controllers/ApiWebhookController.php\n@@ -21,7 +21,7 @@ class ApiWebhookController extends BaseController\n       return self::success("Webhook {$id} created", array_merge(array(\'id\' => $id), $params));\n     else\n       return self::error("Error creating webhook {$id}", false);\n-  }  \n+  }\n \n   /**\n     * Delete a webhook specified by the ID.\n@@ -32,7 +32,7 @@ class ApiWebhookController extends BaseController\n   public static function delete($id)\n   {\n     //getAuthentication()->requireAuthentication();\n-    $status = Webhook::delete($id);   \n+    $status = Webhook::delete($id);\n     if($status)\n       return self::success(\'Webhook deleted successfully\', true);\n     else\ndiff --git a/src/libraries/controllers/BaseController.php b/src/libraries/controllers/BaseController.php\nindex cf988662..c17dfdfc 100644\n--- a/src/libraries/controllers/BaseController.php\n+++ b/src/libraries/controllers/BaseController.php\n@@ -1,7 +1,7 @@\n <?php\n /**\n   * Base controller extended by all other controllers.\n-  * \n+  *\n   * @author Jaisen Mathai <jaisen@jmathai.com>\n  */\n class BaseController\n@@ -20,7 +20,7 @@ class BaseController\n     *\n     * @param string $message A friendly message to describe the operation\n     * @param mixed $result The result with values needed by the caller to take action.\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function created($message, $result = null)\n   {\n@@ -32,7 +32,7 @@ class BaseController\n     *\n     * @param string $message A friendly message to describe the operation\n     * @param mixed $result The result with values needed by the caller to take action.\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function error($message, $result = null)\n   {\n@@ -44,7 +44,7 @@ class BaseController\n     *\n     * @param string $message A friendly message to describe the operation\n     * @param mixed $result The result with values needed by the caller to take action.\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function success($message, $result = null)\n   {\n@@ -56,7 +56,7 @@ class BaseController\n     *\n     * @param string $message A friendly message to describe the operation\n     * @param mixed $result The result with values needed by the caller to take action.\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function forbidden($message, $result = null)\n   {\n@@ -68,7 +68,7 @@ class BaseController\n     *\n     * @param string $message A friendly message to describe the operation\n     * @param mixed $result The result with values needed by the caller to take action.\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   public static function notFound($message, $result = null)\n   {\n@@ -80,7 +80,7 @@ class BaseController\n     *\n     * @param string $message A friendly message to describe the operation\n     * @param mixed $result The result with values needed by the caller to take action.\n-    * @return string Standard JSON envelope \n+    * @return string Standard JSON envelope\n     */\n   private static function json($message, $code, $result = null)\n   {\ndiff --git a/src/libraries/controllers/GroupController.php b/src/libraries/controllers/GroupController.php\nindex e973b902..c181770d 100644\n--- a/src/libraries/controllers/GroupController.php\n+++ b/src/libraries/controllers/GroupController.php\n@@ -1,7 +1,7 @@\n <?php\n /**\n   * Group controller for HTML endpoints.\n-  * \n+  *\n   * @author Jaisen Mathai <jaisen@jmathai.com>\n  */\n class GroupController extends BaseController\ndiff --git a/src/libraries/controllers/SetupController.php b/src/libraries/controllers/SetupController.php\nindex 837ae99e..a97289ea 100644\n--- a/src/libraries/controllers/SetupController.php\n+++ b/src/libraries/controllers/SetupController.php\n@@ -60,7 +60,7 @@ class SetupController\n       $qs = \'?edit\';\n \n     $template = sprintf(\'%s/setup.php\', getConfig()->get(\'paths\')->templates);\n-    $body = getTemplate()->get($template, array(\'filesystem\' => $filesystem, \'database\' => $database, \'themes\' => $themes, \'theme\' => $theme, \n+    $body = getTemplate()->get($template, array(\'filesystem\' => $filesystem, \'database\' => $database, \'themes\' => $themes, \'theme\' => $theme,\n       \'imageLibs\' => $imageLibs, \'imageLibrary\' => $imageLibrary, \'appId\' => $appId, \'step\' => $step, \'email\' => $email, \'qs\' => $qs, \'errors\' => $errors));\n     getTheme()->display(\'template.php\', array(\'body\' => $body, \'page\' => \'setup\'));\n   }\n@@ -348,12 +348,12 @@ class SetupController\n \n     $template = sprintf(\'%s/setup.php\', getConfig()->get(\'paths\')->templates);\n     // copied to/from setup3Post()\n-    $body = getTemplate()->get($template, array(\'step\' => $step, \'themes\' => $themes, \'usesAws\' => $usesAws, \'usesMySql\' => $usesMySql, \n-      \'database\' => $database, \'filesystem\' => $filesystem, \'usesLocalFs\' => $usesLocalFs, \'usesS3\' => $usesS3, \n-      \'usesSimpleDb\' => $usesSimpleDb, \'awsKey\' => $awsKey, \'awsSecret\' => $awsSecret, \'s3Bucket\' => $s3Bucket, \n-      \'simpleDbDomain\' => $simpleDbDomain, \'mySqlHost\' => $mySqlHost, \'mySqlUser\' => $mySqlUser, \'mySqlDb\' => $mySqlDb, \n-      \'mySqlPassword\' => $mySqlPassword, \'mySqlTablePrefix\' => $mySqlTablePrefix, \'fsRoot\' => $fsRoot, \'fsHost\' => $fsHost, \n-      \'usesDropbox\' => $usesDropbox, \'dropboxKey\' => $dropboxKey, \'dropboxSecret\' => $dropboxSecret, \'dropboxToken\' => $dropboxToken, \n+    $body = getTemplate()->get($template, array(\'step\' => $step, \'themes\' => $themes, \'usesAws\' => $usesAws, \'usesMySql\' => $usesMySql,\n+      \'database\' => $database, \'filesystem\' => $filesystem, \'usesLocalFs\' => $usesLocalFs, \'usesS3\' => $usesS3,\n+      \'usesSimpleDb\' => $usesSimpleDb, \'awsKey\' => $awsKey, \'awsSecret\' => $awsSecret, \'s3Bucket\' => $s3Bucket,\n+      \'simpleDbDomain\' => $simpleDbDomain, \'mySqlHost\' => $mySqlHost, \'mySqlUser\' => $mySqlUser, \'mySqlDb\' => $mySqlDb,\n+      \'mySqlPassword\' => $mySqlPassword, \'mySqlTablePrefix\' => $mySqlTablePrefix, \'fsRoot\' => $fsRoot, \'fsHost\' => $fsHost,\n+      \'usesDropbox\' => $usesDropbox, \'dropboxKey\' => $dropboxKey, \'dropboxSecret\' => $dropboxSecret, \'dropboxToken\' => $dropboxToken,\n       \'dropboxTokenSecret\' => $dropboxTokenSecret, \'dropboxFolder\' => $dropboxFolder, \'qs\' => $qs, \'appId\' => $appId, \'errors\' => $errors));\n \n     getTheme()->display(\'template.php\', array(\'body\' => $body, \'page\' => \'setup\'));\n@@ -585,12 +585,12 @@ class SetupController\n \n     $template = sprintf(\'%s/setup.php\', getConfig()->get(\'paths\')->templates);\n     // copied to/from setup3()\n-    $body = getTemplate()->get($template, array(\'step\' => $step, \'themes\' => $themes, \'usesAws\' => $usesAws, \'usesMySql\' => $usesMySql, \n-      \'database\' => $database, \'filesystem\' => $filesystem, \'usesLocalFs\' => $usesLocalFs, \'usesS3\' => $usesS3, \n-      \'usesSimpleDb\' => $usesSimpleDb, \'awsKey\' => $awsKey, \'awsSecret\' => $awsSecret, \'s3Bucket\' => $s3Bucket, \n-      \'simpleDbDomain\' => $simpleDbDomain, \'mySqlHost\' => $mySqlHost, \'mySqlUser\' => $mySqlUser, \'mySqlDb\' => $mySqlDb, \n-      \'mySqlPassword\' => $mySqlPassword, \'mySqlTablePrefix\' => $mySqlTablePrefix, \'fsRoot\' => $fsRoot, \'fsHost\' => $fsHost, \n-      \'usesDropbox\' => $usesDropbox, \'dropboxKey\' => $dropboxKey, \'dropboxSecret\' => $dropboxSecret, \'dropboxToken\' => $dropboxToken, \n+    $body = getTemplate()->get($template, array(\'step\' => $step, \'themes\' => $themes, \'usesAws\' => $usesAws, \'usesMySql\' => $usesMySql,\n+      \'database\' => $database, \'filesystem\' => $filesystem, \'usesLocalFs\' => $usesLocalFs, \'usesS3\' => $usesS3,\n+      \'usesSimpleDb\' => $usesSimpleDb, \'awsKey\' => $awsKey, \'awsSecret\' => $awsSecret, \'s3Bucket\' => $s3Bucket,\n+      \'simpleDbDomain\' => $simpleDbDomain, \'mySqlHost\' => $mySqlHost, \'mySqlUser\' => $mySqlUser, \'mySqlDb\' => $mySqlDb,\n+      \'mySqlPassword\' => $mySqlPassword, \'mySqlTablePrefix\' => $mySqlTablePrefix, \'fsRoot\' => $fsRoot, \'fsHost\' => $fsHost,\n+      \'usesDropbox\' => $usesDropbox, \'dropboxKey\' => $dropboxKey, \'dropboxSecret\' => $dropboxSecret, \'dropboxToken\' => $dropboxToken,\n       \'dropboxTokenSecret\' => $dropboxTokenSecret, \'dropboxFolder\' => $dropboxFolder, \'qs\' => $qs, \'appId\' => $appId, \'errors\' => $errors));\n     getTheme()->display(\'template.php\', array(\'body\' => $body, \'page\' => \'setup\'));\n   }\n@@ -627,9 +627,9 @@ class SetupController\n \n   private static function getDefaultConfigParams()\n   {\n-    return array(\'themes\' => array(), \'awsKey\' => \'\', \'awsSecret\' => \'\', \'s3Bucket\' => \'\', \'simpleDbDomain\' => \'\', \'mySqlHost\' => \'\', \n-      \'mySqlUser\' => \'\', \'mySqlPassword\' => \'\', \'mySqlDb\' => \'\', \'mySqlTablePrefix\' => \'\', \n-      \'fsRoot\' => \'\', \'fsHost\' => \'\', \'dropboxFolder\' => \'\', \'dropboxKey\' => \'\', \'dropboxSecret\' => \'\', \n+    return array(\'themes\' => array(), \'awsKey\' => \'\', \'awsSecret\' => \'\', \'s3Bucket\' => \'\', \'simpleDbDomain\' => \'\', \'mySqlHost\' => \'\',\n+      \'mySqlUser\' => \'\', \'mySqlPassword\' => \'\', \'mySqlDb\' => \'\', \'mySqlTablePrefix\' => \'\',\n+      \'fsRoot\' => \'\', \'fsHost\' => \'\', \'dropboxFolder\' => \'\', \'dropboxKey\' => \'\', \'dropboxSecret\' => \'\',\n       \'dropboxKey\' => \'\', \'dropboxToken\' => \'\', \'dropboxTokenSecret\' => \'\', \'errors\' => \'\');\n   }\n \ndiff --git a/src/libraries/controllers/TagController.php b/src/libraries/controllers/TagController.php\nindex 837fe3c0..b7b895b2 100644\n--- a/src/libraries/controllers/TagController.php\n+++ b/src/libraries/controllers/TagController.php\n@@ -1,7 +1,7 @@\n <?php\n /**\n   * Tag controller for HTML endpoints.\n-  * \n+  *\n   * @author Jaisen Mathai <jaisen@jmathai.com>\n  */\n class TagController extends BaseController\ndiff --git a/src/libraries/controllers/UserController.php b/src/libraries/controllers/UserController.php\nindex 4850cc25..3cedb0f7 100644\n--- a/src/libraries/controllers/UserController.php\n+++ b/src/libraries/controllers/UserController.php\n@@ -1,7 +1,7 @@\n <?php\n /**\n   * User controller for HTML endpoints.\n-  * \n+  *\n   * @author Jaisen Mathai <jaisen@jmathai.com>\n  */\n class UserController extends BaseController\ndiff --git a/src/libraries/external/Dropbox/API.php b/src/libraries/external/Dropbox/API.php\nindex 78b4c326..b91da914 100644\n--- a/src/libraries/external/Dropbox/API.php\n+++ b/src/libraries/external/Dropbox/API.php\n@@ -1,11 +1,11 @@\n <?php\n \n /**\n- * Dropbox API class \n- * \n- * @package Dropbox \n+ * Dropbox API class\n+ *\n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Rooftop Solutions. All rights reserved.\n- * @author Evert Pot (http://www.rooftopsolutions.nl/) \n+ * @author Evert Pot (http://www.rooftopsolutions.nl/)\n  * @license http://code.google.com/p/dropbox-php/wiki/License MIT\n  */\n class Dropbox_API {\n@@ -19,45 +19,45 @@ class Dropbox_API {\n      * Dropbox root-path\n      */\n     const ROOT_DROPBOX = \'dropbox\';\n-    \n+\n     /**\n      * API URl\n      */\n     protected $api_url = \'api.dropbox.com/1/\';\n-    \n+\n     /**\n      * Content API URl\n      */\n     protected $api_content_url = \'api-content.dropbox.com/0/\';\n \n     /**\n-     * OAuth object \n-     * \n+     * OAuth object\n+     *\n      * @var Dropbox_OAuth\n      */\n     protected $oauth;\n-    \n+\n     /**\n-     * Default root-path, this will most likely be \'sandbox\' or \'dropbox\' \n-     * \n-     * @var string \n+     * Default root-path, this will most likely be \'sandbox\' or \'dropbox\'\n+     *\n+     * @var string\n      */\n     protected $root;\n-    \n+\n     /**\n-     * Determines if connections should use SSL or not.  \n+     * Determines if connections should use SSL or not.\n      * Defaults to true in construtor\n-     * \n+     *\n      * @deprecated New Dropbox rest calls require SSL.\n      * @var boolean\n      */\n     protected $useSSL;\n \n     /**\n-     * Constructor \n-     * \n+     * Constructor\n+     *\n      * @param Dropbox_OAuth Dropbox_Auth object\n-     * @param string $root default root path (sandbox or dropbox) \n+     * @param string $root default root path (sandbox or dropbox)\n      */\n     public function __construct(Dropbox_OAuth $oauth, $root = self::ROOT_DROPBOX, $useSSL = true) {\n \n@@ -85,18 +85,18 @@ class Dropbox_API {\n      *   * token\n      *   * secret\n      *\n-     * @param string $email \n-     * @param string $password \n-     * @return array \n+     * @param string $email\n+     * @param string $password\n+     * @return array\n      */\n     public function getToken($email, $password) {\n \n         $data = $this->oauth->fetch($this->api_url . \'token\', array(\n-            \'email\' => $email, \n+            \'email\' => $email,\n             \'password\' => $password\n         ),\'POST\');\n \n-        $data = json_decode($data[\'body\']); \n+        $data = json_decode($data[\'body\']);\n         return array(\n             \'token\' => $data->token,\n             \'token_secret\' => $data->secret,\n@@ -105,9 +105,9 @@ class Dropbox_API {\n     }\n \n     /**\n-     * Returns information about the current dropbox account \n-     * \n-     * @return stdclass \n+     * Returns information about the current dropbox account\n+     *\n+     * @return stdclass\n      */\n     public function getAccountInfo() {\n \n@@ -119,11 +119,11 @@ class Dropbox_API {\n     /**\n      * Creates a new Dropbox account\n      *\n-     * @param string $email \n-     * @param string $first_name \n-     * @param string $last_name \n-     * @param string $password \n-     * @return bool \n+     * @param string $email\n+     * @param string $first_name\n+     * @param string $last_name\n+     * @param string $password\n+     * @return bool\n      */\n     public function createAccount($email, $first_name, $last_name, $password) {\n \n@@ -134,17 +134,17 @@ class Dropbox_API {\n             \'password\'   => $password,\n           ), \'POST\');\n \n-        return $result[\'body\']===\'OK\'; \n+        return $result[\'body\']===\'OK\';\n \n     }\n \n \n     /**\n-     * Returns a file\'s contents \n-     * \n-     * @param string $path path \n-     * @param string $root Use this to override the default root path (sandbox/dropbox) \n-     * @return string \n+     * Returns a file\'s contents\n+     *\n+     * @param string $path path\n+     * @param string $root Use this to override the default root path (sandbox/dropbox)\n+     * @return string\n      */\n     public function getFile($path = \'\', $root = null) {\n \n@@ -158,10 +158,10 @@ class Dropbox_API {\n     /**\n      * Uploads a new file\n      *\n-     * @param string $path Target path (including filename) \n-     * @param string $file Either a path to a file or a stream resource \n-     * @param string $root Use this to override the default root path (sandbox/dropbox)  \n-     * @return bool \n+     * @param string $path Target path (including filename)\n+     * @param string $file Either a path to a file or a stream resource\n+     * @param string $root Use this to override the default root path (sandbox/dropbox)\n+     * @return bool\n      */\n     public function putFile($path, $file, $root = null) {\n \n@@ -178,10 +178,10 @@ class Dropbox_API {\n         } elseif (!is_resource($file)) {\n             throw new Dropbox_Exception(\'File must be a file-resource or a string\');\n         }\n-        $result=$this->multipartFetch($this->api_content_url . \'files/\' . \n+        $result=$this->multipartFetch($this->api_content_url . \'files/\' .\n                 $root . \'/\' . trim($directory,\'/\'), $file, $filename);\n-        \n-        if(!isset($result["httpStatus"]) || $result["httpStatus"] != 200) \n+\n+        if(!isset($result["httpStatus"]) || $result["httpStatus"] != 200)\n             throw new Dropbox_Exception("Uploading file to Dropbox failed");\n \n         return true;\n@@ -189,14 +189,14 @@ class Dropbox_API {\n \n \n     /**\n-     * Copies a file or directory from one location to another \n+     * Copies a file or directory from one location to another\n      *\n      * This method returns the file information of the newly created file.\n      *\n-     * @param string $from source path \n-     * @param string $to destination path \n-     * @param string $root Use this to override the default root path (sandbox/dropbox)  \n-     * @return stdclass \n+     * @param string $from source path\n+     * @param string $to destination path\n+     * @param string $root Use this to override the default root path (sandbox/dropbox)\n+     * @return stdclass\n      */\n     public function copy($from, $to, $root = null) {\n \n@@ -208,13 +208,13 @@ class Dropbox_API {\n     }\n \n     /**\n-     * Creates a new folder \n+     * Creates a new folder\n      *\n      * This method returns the information from the newly created directory\n      *\n-     * @param string $path \n-     * @param string $root Use this to override the default root path (sandbox/dropbox)  \n-     * @return stdclass \n+     * @param string $path\n+     * @param string $root Use this to override the default root path (sandbox/dropbox)\n+     * @return stdclass\n      */\n     public function createFolder($path, $root = null) {\n \n@@ -232,10 +232,10 @@ class Dropbox_API {\n      * Deletes a file or folder.\n      *\n      * This method will return the metadata information from the deleted file or folder, if successful.\n-     * \n-     * @param string $path Path to new folder \n-     * @param string $root Use this to override the default root path (sandbox/dropbox)  \n-     * @return array \n+     *\n+     * @param string $path Path to new folder\n+     * @param string $root Use this to override the default root path (sandbox/dropbox)\n+     * @return array\n      */\n     public function delete($path, $root = null) {\n         if (is_null($root)) $root = $this->root;\n@@ -245,14 +245,14 @@ class Dropbox_API {\n     }\n \n     /**\n-     * Moves a file or directory to a new location \n+     * Moves a file or directory to a new location\n      *\n      * This method returns the information from the newly created directory\n      *\n-     * @param mixed $from Source path \n+     * @param mixed $from Source path\n      * @param mixed $to destination path\n-     * @param string $root Use this to override the default root path (sandbox/dropbox) \n-     * @return stdclass \n+     * @param string $root Use this to override the default root path (sandbox/dropbox)\n+     * @return stdclass\n      */\n     public function move($from, $to, $root = null) {\n \n@@ -272,7 +272,7 @@ class Dropbox_API {\n      * @param string $path Path to directory or file\n      * @param string $root Use this to override the default root path (sandbox/dropbox)\n      * @deprecated This method is no longer supported\n-     * @return array \n+     * @return array\n      */\n     public function getLinks($path, $root = null) {\n \n@@ -280,22 +280,22 @@ class Dropbox_API {\n \n         /*\n         if (is_null($root)) $root = $this->root;\n-        \n+\n         $response = $this->oauth->fetch($this->api_url . \'links/\' . $root . \'/\' . ltrim($path,\'/\'));\n         return json_decode($response,true);\n-        */ \n+        */\n \n     }\n \n     /**\n      * Returns file and directory information\n-     * \n-     * @param string $path Path to receive information from \n+     *\n+     * @param string $path Path to receive information from\n      * @param bool $list When set to true, this method returns information from all files in a directory. When set to false it will only return infromation from the specified directory.\n      * @param string $hash If a hash is supplied, this method simply returns true if nothing has changed since the last request. Good for caching.\n-     * @param int $fileLimit Maximum number of file-information to receive \n-     * @param string $root Use this to override the default root path (sandbox/dropbox) \n-     * @return array|true \n+     * @param int $fileLimit Maximum number of file-information to receive\n+     * @param string $root Use this to override the default root path (sandbox/dropbox)\n+     * @return array|true\n      */\n     public function getMetaData($path, $list = true, $hash = null, $fileLimit = null, $root = null) {\n \n@@ -305,28 +305,28 @@ class Dropbox_API {\n             \'list\' => $list,\n         );\n \n-        if (!is_null($hash)) $args[\'hash\'] = $hash; \n-        if (!is_null($fileLimit)) $args[\'file_limit\'] = $fileLimit; \n+        if (!is_null($hash)) $args[\'hash\'] = $hash;\n+        if (!is_null($fileLimit)) $args[\'file_limit\'] = $fileLimit;\n \n         $path = str_replace(array(\'%2F\',\'~\'), array(\'/\',\'%7E\'), rawurlencode($path));\n         $response = $this->oauth->fetch($this->api_url . \'metadata/\' . $root . \'/\' . ltrim($path,\'/\'), $args);\n \n         /* 304 is not modified */\n         if ($response[\'httpStatus\']==304) {\n-            return true; \n+            return true;\n         } else {\n             return json_decode($response[\'body\'],true);\n         }\n \n-    } \n+    }\n \n     /**\n-     * Returns a thumbnail (as a string) for a file path. \n-     * \n-     * @param string $path Path to file \n-     * @param string $size small, medium or large \n-     * @param string $root Use this to override the default root path (sandbox/dropbox)  \n-     * @return string \n+     * Returns a thumbnail (as a string) for a file path.\n+     *\n+     * @param string $path Path to file\n+     * @param string $size small, medium or large\n+     * @param string $root Use this to override the default root path (sandbox/dropbox)\n+     * @return string\n      */\n     public function getThumbnail($path, $size = \'small\', $root = null) {\n \n@@ -338,11 +338,11 @@ class Dropbox_API {\n     }\n \n     /**\n-     * This method is used to generate multipart POST requests for file upload \n-     * \n-     * @param string $uri \n-     * @param array $arguments \n-     * @return bool \n+     * This method is used to generate multipart POST requests for file upload\n+     *\n+     * @param string $uri\n+     * @param array $arguments\n+     * @return bool\n      */\n     protected function multipartFetch($uri, $file, $filename) {\n \n@@ -362,7 +362,7 @@ class Dropbox_API {\n         $body.="--" . $boundary . "--";\n \n         // Dropbox requires the filename to also be part of the regular arguments, so it becomes\n-        // part of the signature. \n+        // part of the signature.\n         $uri.=\'?file=\' . $filename;\n \n         return $this->oauth->fetch($uri, $body, \'POST\', $headers);\ndiff --git a/src/libraries/external/Dropbox/Exception.php b/src/libraries/external/Dropbox/Exception.php\nindex 50cbc4c7..2f80d090 100644\n--- a/src/libraries/external/Dropbox/Exception.php\n+++ b/src/libraries/external/Dropbox/Exception.php\n@@ -1,11 +1,11 @@\n <?php\n \n /**\n- * Dropbox base exception \n- * \n- * @package Dropbox \n+ * Dropbox base exception\n+ *\n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Rooftop Solutions. All rights reserved.\n- * @author Evert Pot (http://www.rooftopsolutions.nl/) \n+ * @author Evert Pot (http://www.rooftopsolutions.nl/)\n  * @license http://code.google.com/p/dropbox-php/wiki/License MIT\n  */\n \ndiff --git a/src/libraries/external/Dropbox/Exception/Forbidden.php b/src/libraries/external/Dropbox/Exception/Forbidden.php\nindex 5f0378cf..39d2f6d7 100644\n--- a/src/libraries/external/Dropbox/Exception/Forbidden.php\n+++ b/src/libraries/external/Dropbox/Exception/Forbidden.php\n@@ -2,10 +2,10 @@\n \n /**\n  * Dropbox Forbidden exception\n- * \n- * @package Dropbox \n+ *\n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Rooftop Solutions. All rights reserved.\n- * @author Evert Pot (http://www.rooftopsolutions.nl/) \n+ * @author Evert Pot (http://www.rooftopsolutions.nl/)\n  * @license http://code.google.com/p/dropbox-php/wiki/License MIT\n  */\n \ndiff --git a/src/libraries/external/Dropbox/Exception/NotFound.php b/src/libraries/external/Dropbox/Exception/NotFound.php\nindex 3deaf90d..109fdf83 100644\n--- a/src/libraries/external/Dropbox/Exception/NotFound.php\n+++ b/src/libraries/external/Dropbox/Exception/NotFound.php\n@@ -2,16 +2,16 @@\n \n /**\n  * Dropbox Not Found exception\n- * \n- * @package Dropbox \n+ *\n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Rooftop Solutions. All rights reserved.\n- * @author Evert Pot (http://www.rooftopsolutions.nl/) \n+ * @author Evert Pot (http://www.rooftopsolutions.nl/)\n  * @license http://code.google.com/p/dropbox-php/wiki/License MIT\n  */\n \n /**\n  * This exception is thrown when a non-existant uri is accessed.\n- * \n+ *\n  * Basically, this exception is used when we get back a 404.\n  */\n class Dropbox_Exception_NotFound extends Dropbox_Exception {\ndiff --git a/src/libraries/external/Dropbox/Exception/OverQuota.php b/src/libraries/external/Dropbox/Exception/OverQuota.php\nindex 86e5425d..fd4e33ca 100644\n--- a/src/libraries/external/Dropbox/Exception/OverQuota.php\n+++ b/src/libraries/external/Dropbox/Exception/OverQuota.php\n@@ -2,16 +2,16 @@\n \n /**\n  * Dropbox Over Quota exception\n- * \n- * @package Dropbox \n+ *\n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Rooftop Solutions. All rights reserved.\n- * @author Evert Pot (http://www.rooftopsolutions.nl/) \n+ * @author Evert Pot (http://www.rooftopsolutions.nl/)\n  * @license http://code.google.com/p/dropbox-php/wiki/License MIT\n  */\n \n /**\n  * This exception is thrown when the operation required more space than the available quota.\n- * \n+ *\n  * Basically, this exception is used when we get back a 507.\n  */\n class Dropbox_Exception_OverQuota extends Dropbox_Exception {\ndiff --git a/src/libraries/external/Dropbox/Exception/RequestToken.php b/src/libraries/external/Dropbox/Exception/RequestToken.php\nindex 5b117f2c..ab7b4460 100644\n--- a/src/libraries/external/Dropbox/Exception/RequestToken.php\n+++ b/src/libraries/external/Dropbox/Exception/RequestToken.php\n@@ -2,10 +2,10 @@\n \n /**\n  * Dropbox RequestToken exception\n- * \n- * @package Dropbox \n+ *\n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Rooftop Solutions. All rights reserved.\n- * @author Evert Pot (http://www.rooftopsolutions.nl/) \n+ * @author Evert Pot (http://www.rooftopsolutions.nl/)\n  * @license http://code.google.com/p/dropbox-php/wiki/License MIT\n  */\n \ndiff --git a/src/libraries/external/Dropbox/OAuth.php b/src/libraries/external/Dropbox/OAuth.php\nindex ed200318..b2e76e67 100644\n--- a/src/libraries/external/Dropbox/OAuth.php\n+++ b/src/libraries/external/Dropbox/OAuth.php\n@@ -2,10 +2,10 @@\n \n /**\n  * Dropbox OAuth\n- * \n- * @package Dropbox \n+ *\n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Rooftop Solutions. All rights reserved.\n- * @author Evert Pot (http://www.rooftopsolutions.nl/) \n+ * @author Evert Pot (http://www.rooftopsolutions.nl/)\n  * @license http://code.google.com/p/dropbox-php/wiki/License MIT\n  */\n \n@@ -21,52 +21,52 @@ abstract class Dropbox_OAuth {\n     /**\n      * After a user has authorized access, dropbox can redirect the user back\n      * to this url.\n-     * \n+     *\n      * @var string\n      */\n-    public $authorizeCallbackUrl = null; \n-   \n+    public $authorizeCallbackUrl = null;\n+\n     /**\n-     * Uri used to fetch request tokens \n-     * \n+     * Uri used to fetch request tokens\n+     *\n      * @var string\n      */\n     const URI_REQUEST_TOKEN = \'http://api.dropbox.com/0/oauth/request_token\';\n \n     /**\n      * Uri used to redirect the user to for authorization.\n-     * \n+     *\n      * @var string\n      */\n     const URI_AUTHORIZE = \'http://www.dropbox.com/0/oauth/authorize\';\n \n     /**\n-     * Uri used to \n-     * \n+     * Uri used to\n+     *\n      * @var string\n      */\n     const URI_ACCESS_TOKEN = \'http://api.dropbox.com/0/oauth/access_token\';\n \n     /**\n-     * An OAuth request token. \n-     * \n-     * @var string \n+     * An OAuth request token.\n+     *\n+     * @var string\n      */\n     protected $oauth_token = null;\n \n     /**\n-     * OAuth token secret \n-     * \n-     * @var string \n+     * OAuth token secret\n+     *\n+     * @var string\n      */\n     protected $oauth_token_secret = null;\n \n \n     /**\n      * Constructor\n-     * \n-     * @param string $consumerKey \n-     * @param string $consumerSecret \n+     *\n+     * @param string $consumerKey\n+     * @param string $consumerSecret\n      */\n     abstract public function __construct($consumerKey, $consumerSecret);\n \n@@ -75,9 +75,9 @@ abstract class Dropbox_OAuth {\n      *\n      * The tokens can also be passed as an array into the first argument.\n      * The array must have the elements token and token_secret.\n-     * \n-     * @param string|array $token \n-     * @param string $token_secret \n+     *\n+     * @param string|array $token\n+     * @param string $token_secret\n      * @return void\n      */\n     public function setToken($token, $token_secret = null) {\n@@ -96,8 +96,8 @@ abstract class Dropbox_OAuth {\n      * Returns the oauth request tokens as an associative array.\n      *\n      * The array will contain the elements \'token\' and \'token_secret\'.\n-     * \n-     * @return array \n+     *\n+     * @return array\n      */\n     public function getToken() {\n \n@@ -110,12 +110,12 @@ abstract class Dropbox_OAuth {\n \n     /**\n      * Returns the authorization url\n-     * \n-     * @param string $callBack Specify a callback url to automatically redirect the user back \n-     * @return string \n+     *\n+     * @param string $callBack Specify a callback url to automatically redirect the user back\n+     * @return string\n      */\n     public function getAuthorizeUrl($callBack = null) {\n-        \n+\n         // Building the redirect uri\n         $token = $this->getToken();\n         $uri = self::URI_AUTHORIZE . \'?oauth_token=\' . $token[\'token\'];\n@@ -124,28 +124,28 @@ abstract class Dropbox_OAuth {\n     }\n \n     /**\n-     * Fetches a secured oauth url and returns the response body. \n-     * \n-     * @param string $uri \n-     * @param mixed $arguments \n-     * @param string $method \n-     * @param array $httpHeaders \n-     * @return string \n+     * Fetches a secured oauth url and returns the response body.\n+     *\n+     * @param string $uri\n+     * @param mixed $arguments\n+     * @param string $method\n+     * @param array $httpHeaders\n+     * @return string\n      */\n-    public abstract function fetch($uri, $arguments = array(), $method = \'GET\', $httpHeaders = array()); \n+    public abstract function fetch($uri, $arguments = array(), $method = \'GET\', $httpHeaders = array());\n \n     /**\n      * Requests the OAuth request token.\n-     * \n-     * @return array \n+     *\n+     * @return array\n      */\n-    abstract public function getRequestToken(); \n+    abstract public function getRequestToken();\n \n     /**\n      * Requests the OAuth access tokens.\n      *\n      * @return array\n      */\n-    abstract public function getAccessToken(); \n+    abstract public function getAccessToken();\n \n }\ndiff --git a/src/libraries/external/Dropbox/OAuth/PEAR.php b/src/libraries/external/Dropbox/OAuth/PEAR.php\nindex 3c365169..96182cd7 100644\n--- a/src/libraries/external/Dropbox/OAuth/PEAR.php\n+++ b/src/libraries/external/Dropbox/OAuth/PEAR.php\n@@ -2,17 +2,17 @@\n \n /**\n  * Dropbox OAuth\n- * \n- * @package Dropbox \n+ *\n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Rooftop Solutions. All rights reserved.\n- * @author Evert Pot (http://www.rooftopsolutions.nl/) \n+ * @author Evert Pot (http://www.rooftopsolutions.nl/)\n  * @license http://code.google.com/p/dropbox-php/wiki/License MIT\n  */\n \n \n /**\n  * This class is used to sign all requests to dropbox\n- * \n+ *\n  * This classes use the PEAR HTTP_OAuth package. Make sure this is installed.\n  */\n class Dropbox_OAuth_PEAR extends Dropbox_OAuth {\n@@ -26,18 +26,18 @@ class Dropbox_OAuth_PEAR extends Dropbox_OAuth {\n \n     /**\n      * OAuth consumer key\n-     * \n-     * We need to keep this around for later. \n-     * \n-     * @var string \n+     *\n+     * We need to keep this around for later.\n+     *\n+     * @var string\n      */\n     protected $consumerKey;\n \n     /**\n      * Constructor\n-     * \n-     * @param string $consumerKey \n-     * @param string $consumerSecret \n+     *\n+     * @param string $consumerKey\n+     * @param string $consumerSecret\n      */\n     public function __construct($consumerKey, $consumerSecret) {\n \n@@ -47,7 +47,7 @@ class Dropbox_OAuth_PEAR extends Dropbox_OAuth {\n             include \'HTTP/OAuth/Consumer.php\';\n \n         }\n-        if (!class_exists(\'HTTP_OAuth_Consumer\')) \n+        if (!class_exists(\'HTTP_OAuth_Consumer\'))\n             throw new Dropbox_Exception(\'The HTTP_OAuth_Consumer class could not be found! Did you install the pear HTTP_OAUTH class?\');\n \n         $this->OAuth = new HTTP_OAuth_Consumer($consumerKey, $consumerSecret);\n@@ -60,9 +60,9 @@ class Dropbox_OAuth_PEAR extends Dropbox_OAuth {\n      *\n      * The tokens can also be passed as an array into the first argument.\n      * The array must have the elements token and token_secret.\n-     * \n-     * @param string|array $token \n-     * @param string $token_secret \n+     *\n+     * @param string|array $token\n+     * @param string $token_secret\n      * @return void\n      */\n     public function setToken($token, $token_secret = null) {\n@@ -74,20 +74,20 @@ class Dropbox_OAuth_PEAR extends Dropbox_OAuth {\n     }\n \n     /**\n-     * Fetches a secured oauth url and returns the response body. \n-     * \n-     * @param string $uri \n-     * @param mixed $arguments \n-     * @param string $method \n-     * @param array $httpHeaders \n-     * @return string \n+     * Fetches a secured oauth url and returns the response body.\n+     *\n+     * @param string $uri\n+     * @param mixed $arguments\n+     * @param string $method\n+     * @param array $httpHeaders\n+     * @return string\n      */\n     public function fetch($uri, $arguments = array(), $method = \'GET\', $httpHeaders = array())\n     {\n-        $httpRequest = new HTTP_Request2(null, \n-                HTTP_Request2::METHOD_GET, \n+        $httpRequest = new HTTP_Request2(null,\n+                HTTP_Request2::METHOD_GET,\n                 array(\n-                    \'ssl_verify_peer\' => false, \n+                    \'ssl_verify_peer\' => false,\n                     \'ssl_verify_host\' => false\n                 )\n         );\n@@ -97,7 +97,7 @@ class Dropbox_OAuth_PEAR extends Dropbox_OAuth {\n         $consumerRequest->setUrl($uri);\n         $consumerRequest->setMethod($method);\n         $consumerRequest->setSecrets($this->OAuth->getSecrets());\n-     \n+\n         $parameters = array(\n             \'oauth_consumer_key\'     => $this->consumerKey,\n             \'oauth_signature_method\' => \'HMAC-SHA1\',\n@@ -132,9 +132,9 @@ class Dropbox_OAuth_PEAR extends Dropbox_OAuth {\n                 break;\n             case 403 :\n                 throw new Dropbox_Exception_Forbidden(\'Forbidden. This could mean a bad OAuth request, or a file or folder already existing at the target location.\');\n-            case 404 : \n+            case 404 :\n                 throw new Dropbox_Exception_NotFound(\'Resource at uri: \' . $uri . \' could not be found\');\n-            case 507 : \n+            case 507 :\n                 throw new Dropbox_Exception_OverQuota(\'This dropbox is full\');\n \n         }\n@@ -148,11 +148,11 @@ class Dropbox_OAuth_PEAR extends Dropbox_OAuth {\n \n     /**\n      * Requests the OAuth request token.\n-     * \n+     *\n      * @return void\n      */\n     public function getRequestToken() {\n-        \n+\n         $this->OAuth->getRequestToken(self::URI_REQUEST_TOKEN);\n         $this->setToken($this->OAuth->getToken(), $this->OAuth->getTokenSecret());\n         return $this->getToken();\n@@ -164,8 +164,8 @@ class Dropbox_OAuth_PEAR extends Dropbox_OAuth {\n      *\n      * This method requires the \'unauthorized\' request tokens\n      * and, if successful will set the authorized request tokens.\n-     * \n-     * @return void \n+     *\n+     * @return void\n      */\n     public function getAccessToken() {\n \ndiff --git a/src/libraries/external/Dropbox/OAuth/PHP.php b/src/libraries/external/Dropbox/OAuth/PHP.php\nindex 48ce66f1..1709012f 100644\n--- a/src/libraries/external/Dropbox/OAuth/PHP.php\n+++ b/src/libraries/external/Dropbox/OAuth/PHP.php\n@@ -2,10 +2,10 @@\n \n /**\n  * Dropbox OAuth\n- * \n- * @package Dropbox \n+ *\n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Rooftop Solutions. All rights reserved.\n- * @author Evert Pot (http://www.rooftopsolutions.nl/) \n+ * @author Evert Pot (http://www.rooftopsolutions.nl/)\n  * @license http://code.google.com/p/dropbox-php/wiki/License MIT\n  */\n \n@@ -26,13 +26,13 @@ class Dropbox_OAuth_PHP extends Dropbox_OAuth {\n \n     /**\n      * Constructor\n-     * \n-     * @param string $consumerKey \n-     * @param string $consumerSecret \n+     *\n+     * @param string $consumerKey\n+     * @param string $consumerSecret\n      */\n     public function __construct($consumerKey, $consumerSecret) {\n \n-        if (!class_exists(\'OAuth\')) \n+        if (!class_exists(\'OAuth\'))\n             throw new Dropbox_Exception(\'The OAuth class could not be found! Did you install and enable the oauth extension?\');\n \n         $this->OAuth = new OAuth($consumerKey, $consumerSecret,OAUTH_SIG_METHOD_HMACSHA1,OAUTH_AUTH_TYPE_URI);\n@@ -45,9 +45,9 @@ class Dropbox_OAuth_PHP extends Dropbox_OAuth {\n      *\n      * The tokens can also be passed as an array into the first argument.\n      * The array must have the elements token and token_secret.\n-     * \n-     * @param string|array $token \n-     * @param string $token_secret \n+     *\n+     * @param string|array $token\n+     * @param string $token_secret\n      * @return void\n      */\n     public function setToken($token, $token_secret = null) {\n@@ -59,17 +59,17 @@ class Dropbox_OAuth_PHP extends Dropbox_OAuth {\n \n \n     /**\n-     * Fetches a secured oauth url and returns the response body. \n-     * \n-     * @param string $uri \n-     * @param mixed $arguments \n-     * @param string $method \n-     * @param array $httpHeaders \n-     * @return string \n+     * Fetches a secured oauth url and returns the response body.\n+     *\n+     * @param string $uri\n+     * @param mixed $arguments\n+     * @param string $method\n+     * @param array $httpHeaders\n+     * @return string\n      */\n     public function fetch($uri, $arguments = array(), $method = \'GET\', $httpHeaders = array()) {\n \n-        try { \n+        try {\n             $this->OAuth->fetch($uri, $arguments, $method, $httpHeaders);\n             $result = $this->OAuth->getLastResponse();\n             $lastResponseInfo = $this->OAuth->getLastResponseInfo();\n@@ -91,9 +91,9 @@ class Dropbox_OAuth_PHP extends Dropbox_OAuth {\n                     break;\n                 case 403 :\n                     throw new Dropbox_Exception_Forbidden(\'Forbidden. This could mean a bad OAuth request, or a file or folder already existing at the target location.\');\n-                case 404 : \n+                case 404 :\n                     throw new Dropbox_Exception_NotFound(\'Resource at uri: \' . $uri . \' could not be found\');\n-                case 507 : \n+                case 507 :\n                     throw new Dropbox_Exception_OverQuota(\'This dropbox is full\');\n                 default:\n                     // rethrowing\n@@ -107,10 +107,10 @@ class Dropbox_OAuth_PHP extends Dropbox_OAuth {\n     /**\n      * Requests the OAuth request token.\n      *\n-     * @return void \n+     * @return void\n      */\n     public function getRequestToken() {\n-        \n+\n         try {\n \n             $tokens = $this->OAuth->getRequestToken(self::URI_REQUEST_TOKEN);\n@@ -131,8 +131,8 @@ class Dropbox_OAuth_PHP extends Dropbox_OAuth {\n      *\n      * This method requires the \'unauthorized\' request tokens\n      * and, if successful will set the authorized request tokens.\n-     * \n-     * @return void \n+     *\n+     * @return void\n      */\n     public function getAccessToken() {\n \ndiff --git a/src/libraries/external/Dropbox/OAuth/Wordpress.php b/src/libraries/external/Dropbox/OAuth/Wordpress.php\nindex 66ee595f..3c9316e6 100644\n--- a/src/libraries/external/Dropbox/OAuth/Wordpress.php\n+++ b/src/libraries/external/Dropbox/OAuth/Wordpress.php\n@@ -2,8 +2,8 @@\n \n /**\n  * Dropbox OAuth\n- * \n- * @package Dropbox \n+ *\n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Stefan Motz\n  * @author Stefan Motz (http://www.multimediamotz.de/)\n  * @license MIT\n@@ -29,9 +29,9 @@ class Dropbox_OAuth_Wordpress extends Dropbox_OAuth {\n \n     /**\n      * Constructor\n-     * \n-     * @param string $consumerKey \n-     * @param string $consumerSecret \n+     *\n+     * @param string $consumerKey\n+     * @param string $consumerSecret\n      */\n     public function __construct($consumerKey, $consumerSecret) {\n         if (!(defined(\'ABSPATH\') && defined(\'WPINC\')))\n@@ -45,13 +45,13 @@ class Dropbox_OAuth_Wordpress extends Dropbox_OAuth {\n     }\n \n     /**\n-     * Fetches a secured oauth url and returns the response body. \n-     * \n-     * @param string $uri \n-     * @param mixed $arguments \n-     * @param string $method \n-     * @param array $httpHeaders \n-     * @return string \n+     * Fetches a secured oauth url and returns the response body.\n+     *\n+     * @param string $uri\n+     * @param mixed $arguments\n+     * @param string $method\n+     * @param array $httpHeaders\n+     * @return string\n      */\n     public function fetch($uri, $arguments = array(), $method = \'GET\', $httpHeaders = array()) {\n \n@@ -149,7 +149,7 @@ class Dropbox_OAuth_Wordpress extends Dropbox_OAuth {\n     /**\n      * Requests the OAuth request token.\n      *\n-     * @return void \n+     * @return void\n      */\n     public function getRequestToken() {\n         $result = $this->fetch(self::URI_REQUEST_TOKEN, array(), \'POST\');\n@@ -168,8 +168,8 @@ class Dropbox_OAuth_Wordpress extends Dropbox_OAuth {\n      *\n      * This method requires the \'unauthorized\' request tokens\n      * and, if successful will set the authorized request tokens.\n-     * \n-     * @return void \n+     *\n+     * @return void\n      */\n     public function getAccessToken() {\n         $result = $this->fetch(self::URI_ACCESS_TOKEN, array(), \'POST\');\ndiff --git a/src/libraries/external/Dropbox/autoload.php b/src/libraries/external/Dropbox/autoload.php\nindex 5388ea63..bbff9339 100644\n--- a/src/libraries/external/Dropbox/autoload.php\n+++ b/src/libraries/external/Dropbox/autoload.php\n@@ -1,11 +1,11 @@\n <?php\n \n /**\n- * This file registers a new autoload function using spl_autoload_register. \n+ * This file registers a new autoload function using spl_autoload_register.\n  *\n- * @package Dropbox \n+ * @package Dropbox\n  * @copyright Copyright (C) 2010 Rooftop Solutions. All rights reserved.\n- * @author Evert Pot (http://www.rooftopsolutions.nl/) \n+ * @author Evert Pot (http://www.rooftopsolutions.nl/)\n  * @license http://code.google.com/p/dropbox-php/wiki/License MIT\n  */\n \ndiff --git a/src/libraries/external/epi/EpiApi.php b/src/libraries/external/epi/EpiApi.php\nindex 3243b7b9..600e6c62 100644\n--- a/src/libraries/external/epi/EpiApi.php\n+++ b/src/libraries/external/epi/EpiApi.php\n@@ -45,13 +45,13 @@ class EpiApi\n \n     // restore sanity\n     foreach($tmps as $type => $value)\n-      $GLOBALS[$type] = $value; \n+      $GLOBALS[$type] = $value;\n \n     return $retval;\n   }\n \n   /**\n-   * EpiApi::getRoute($route); \n+   * EpiApi::getRoute($route);\n    * @name  getRoute\n    * @author  Jaisen Mathai <jaisen@jmathai.com>\n    * @param string $route\ndiff --git a/src/libraries/external/epi/EpiCache.php b/src/libraries/external/epi/EpiCache.php\nindex 6587d2d8..8f981e95 100644\n--- a/src/libraries/external/epi/EpiCache.php\n+++ b/src/libraries/external/epi/EpiCache.php\n@@ -6,7 +6,7 @@ class EpiCache\n   private static $instances, $employ;\n   private $cached, $hash;\n   private function __construct(){}\n-  \n+\n   /*\n    * @param  type  required\n    * @params optional\n@@ -46,7 +46,7 @@ class EpiCache\n     $params = func_get_args();\n     return $this->get(implode(\'.\', $params));\n   }\n- \n+\n   protected function setByKey()\n   {\n     $params = func_get_args();\ndiff --git a/src/libraries/external/epi/EpiCache_Memcached.php b/src/libraries/external/epi/EpiCache_Memcached.php\nindex 42e39c43..b47458d7 100644\n--- a/src/libraries/external/epi/EpiCache_Memcached.php\n+++ b/src/libraries/external/epi/EpiCache_Memcached.php\n@@ -60,7 +60,7 @@ class EpiCache_Memcached extends EpiCache\n     if(class_exists(\'Memcached\'))\n     {\n       $this->memcached = new Memcached;\n-      \n+\n       if($this->memcached->addServer($this->host, $this->port))\n         return self::$connected = true;\n       else\ndiff --git a/src/libraries/external/epi/EpiConfig.php b/src/libraries/external/epi/EpiConfig.php\nindex d1c70612..012f6114 100644\n--- a/src/libraries/external/epi/EpiConfig.php\n+++ b/src/libraries/external/epi/EpiConfig.php\n@@ -64,7 +64,7 @@ class EpiConfig\n \n     self::$instance = new EpiConfig;\n     return self::$instance;\n-  }  \n+  }\n }\n \n function getConfig()\ndiff --git a/src/libraries/external/epi/EpiCurl.php b/src/libraries/external/epi/EpiCurl.php\nindex 96455bc1..5a2f329b 100644\n--- a/src/libraries/external/epi/EpiCurl.php\n+++ b/src/libraries/external/epi/EpiCurl.php\n@@ -51,7 +51,7 @@ class EpiCurl\n \n     $code = curl_multi_add_handle($this->mc, $ch);\n     $this->startTimer($key);\n-    \n+\n     // (1)\n     if($code === CURLM_OK || $code === CURLM_CALL_MULTI_PERFORM)\n     {\ndiff --git a/src/libraries/external/epi/EpiDatabase.php b/src/libraries/external/epi/EpiDatabase.php\nindex 907547ff..25bcb5ad 100644\n--- a/src/libraries/external/epi/EpiDatabase.php\n+++ b/src/libraries/external/epi/EpiDatabase.php\n@@ -6,7 +6,7 @@ class EpiDatabase\n   private $_type, $_name, $_host, $_user, $_pass;\n   public $dbh;\n   private function __construct(){}\n-  \n+\n   public static function getInstance($type, $name, $host = \'localhost\', $user = \'root\', $pass = \'\')\n   {\n     $args = func_get_args();\n@@ -22,8 +22,8 @@ class EpiDatabase\n     self::$instances[$hash]->_pass = $pass;\n     return self::$instances[$hash];\n   }\n-  \n-  /** \n+\n+  /**\n    * @return false in case of error\n    */\n   public function execute($sql = false, $params = array())\n@@ -45,7 +45,7 @@ class EpiDatabase\n       return false;\n     }\n   }\n-  \n+\n   public function insertId()\n   {\n     $this->init();\n@@ -55,7 +55,7 @@ class EpiDatabase\n     }\n     return false;\n   }\n-  \n+\n   public function all($sql = false, $params = array())\n   {\n     $this->init();\n@@ -70,7 +70,7 @@ class EpiDatabase\n       return false;\n     }\n   }\n-  \n+\n   public function one($sql = false, $params = array())\n   {\n     $this->init();\ndiff --git a/src/libraries/external/epi/EpiLogger.php b/src/libraries/external/epi/EpiLogger.php\nindex a91f1f92..2686e1eb 100644\n--- a/src/libraries/external/epi/EpiLogger.php\n+++ b/src/libraries/external/epi/EpiLogger.php\n@@ -19,7 +19,7 @@ class EpiLogger\n       }\n     }\n   }\n-  \n+\n   public function crit($message, $exception = null)\n   {\n     if(!isset($this->levels[self::Crit]))\n@@ -27,7 +27,7 @@ class EpiLogger\n \n     $this->log($message, self::Crit, $exception);\n   }\n-  \n+\n   public function info($message, $exception = null)\n   {\n     if(!isset($this->levels[self::Info]))\n@@ -35,7 +35,7 @@ class EpiLogger\n \n     $this->log($message, self::Info, $exception);\n   }\n-  \n+\n   public function warn($message, $exception = null)\n   {\n     if(!isset($this->levels[self::Warn]))\ndiff --git a/src/libraries/external/epi/EpiRoute.php b/src/libraries/external/epi/EpiRoute.php\nindex aca0c396..4f7f67cb 100644\n--- a/src/libraries/external/epi/EpiRoute.php\n+++ b/src/libraries/external/epi/EpiRoute.php\n@@ -4,7 +4,7 @@\n  *\n  * This contains the EpiRoute class as wel as the EpiException abstract class\n  * @author  Jaisen Mathai <jaisen@jmathai.com>\n- * @version 1.0  \n+ * @version 1.0\n  * @package EpiRoute\n  */\n \n@@ -47,7 +47,7 @@ class EpiRoute\n   {\n     $this->addRoute($route, $callback, self::httpPost, $isApi);\n   }\n-  \n+\n   /**\n    * NOT YET IMPLEMENTED\n    * request(\'/\', \'function\', array(EpiRoute::httpGet, EpiRoute::httpPost));\n@@ -85,9 +85,9 @@ class EpiRoute\n         $this->$method($route[\'path\'], $route[\'function\']);\n     }\n   }\n-  \n+\n   /**\n-   * EpiRoute::run($_GET[\'__route__\'], $_[\'routes\']); \n+   * EpiRoute::run($_GET[\'__route__\'], $_[\'routes\']);\n    * @name  run\n    * @author  Jaisen Mathai <jaisen@jmathai.com>\n    * @param string $route\n@@ -116,7 +116,7 @@ class EpiRoute\n \n \n   /**\n-   * EpiRoute::getRoute($route); \n+   * EpiRoute::getRoute($route);\n    * @name  getRoute\n    * @author  Jaisen Mathai <jaisen@jmathai.com>\n    * @param string $route\n@@ -163,7 +163,7 @@ class EpiRoute\n   }\n \n   /**\n-   * EpiRoute::redirect($url); \n+   * EpiRoute::redirect($url);\n    * @name  redirect\n    * @author  Jaisen Mathai <jaisen@jmathai.com>\n    * @param string $url\ndiff --git a/src/libraries/external/epi/EpiSession_Apc.php b/src/libraries/external/epi/EpiSession_Apc.php\nindex 65e10ea4..1e62b5a7 100644\n--- a/src/libraries/external/epi/EpiSession_Apc.php\n+++ b/src/libraries/external/epi/EpiSession_Apc.php\n@@ -27,7 +27,7 @@ class EpiSession_Apc implements EpiSessionInterface\n   {\n     if(empty($key))\n       return false;\n-    \n+\n     $this->store[$key] = $value;\n     apc_store($this->key, $this->store);\n     return $value;\ndiff --git a/src/libraries/external/epi/EpiSession_Memcached.php b/src/libraries/external/epi/EpiSession_Memcached.php\nindex 8ecdae17..2f5cef19 100644\n--- a/src/libraries/external/epi/EpiSession_Memcached.php\n+++ b/src/libraries/external/epi/EpiSession_Memcached.php\n@@ -49,7 +49,7 @@ class EpiSession_Memcached implements EpiSessionInterface\n   {\n     if(!$this->connect() || empty($key))\n       return false;\n-    \n+\n     $this->store[$key] = $value;\n     $this->memcached->set($this->key, $this->store);\n     return $value;\ndiff --git a/src/libraries/external/epi/EpiTemplate.php b/src/libraries/external/epi/EpiTemplate.php\nindex b0c68470..fa36b909 100644\n--- a/src/libraries/external/epi/EpiTemplate.php\n+++ b/src/libraries/external/epi/EpiTemplate.php\n@@ -19,7 +19,7 @@ class EpiTemplate\n       {\n         extract($vars);\n       }\n-      \n+\n       include $templateInclude;\n     }\n     else\n@@ -27,7 +27,7 @@ class EpiTemplate\n       EpiException::raise(new EpiException("Could not load template: {$templateInclude}", 404));\n     }\n   }\n-  \n+\n   /**\n    * EpiRoute::get(\'/path/to/template.php\', $array);\n    * @name  get\n@@ -57,9 +57,9 @@ class EpiTemplate\n       EpiException::raise(new EpiException("Could not load template: {$templateInclude}", 404));\n     }\n   }\n-  \n+\n   /**\n-   * EpiRoute::json($variable); \n+   * EpiRoute::json($variable);\n    * @name  json\n    * @author  Jaisen Mathai <jaisen@jmathai.com>\n    * @param mixed $data\n@@ -79,9 +79,9 @@ class EpiTemplate\n       EpiException::raise(new EpiException("json_encode failed for {$dataDump}", 404));\n     }\n   }\n-  \n+\n   /**\n-   * EpiRoute::jsonResponse($variable); \n+   * EpiRoute::jsonResponse($variable);\n    * This method echo\'s JSON data in the header and to the screen and returns.\n    * @name  jsonResponse\n    * @author  Jaisen Mathai <jaisen@jmathai.com>\ndiff --git a/src/libraries/initialize.php b/src/libraries/initialize.php\nindex e1aa168f..2a5aa6d6 100644\n--- a/src/libraries/initialize.php\n+++ b/src/libraries/initialize.php\n@@ -37,7 +37,7 @@ else\n   // if we\'re running setup and the config file exists, load it to prepopulate the form\n   if(file_exists($configFile))\n     getConfig()->load(sprintf(\'generated/%s.ini\', getenv(\'HTTP_HOST\')));\n-    \n+\n   // setup and enable routes for setup\n   $baseDir = dirname(dirname(__FILE__));\n   $paths = new stdClass;\ndiff --git a/src/libraries/models/Action.php b/src/libraries/models/Action.php\nindex 1f4ccd30..f09eea7d 100644\n--- a/src/libraries/models/Action.php\n+++ b/src/libraries/models/Action.php\n@@ -12,7 +12,7 @@ class Action\n     * Accepts a set of params that must include a type and targetType\n     *\n     * @param array $params Params describing the action to be added\n-    * @return mixed Action ID on success, false on failure \n+    * @return mixed Action ID on success, false on failure\n     */\n   public static function add($params)\n   {\ndiff --git a/src/libraries/models/Credential.php b/src/libraries/models/Credential.php\nindex 42fcc914..d92ef86a 100644\n--- a/src/libraries/models/Credential.php\n+++ b/src/libraries/models/Credential.php\n@@ -41,7 +41,7 @@ class Credential\n     $res = getDb()->putCredential($id, $params);\n     if($res)\n       return $id;\n-    \n+\n     return false;\n   }\n \n@@ -67,7 +67,7 @@ class Credential\n \n     try\n     {\n-      $this->provider->consumerHandler(array($this,\'checkConsumer\'));\t\n+      $this->provider->consumerHandler(array($this,\'checkConsumer\'));\n       $this->provider->timestampNonceHandler(array($this,\'checkTimestampAndNonce\'));\n       $this->provider->tokenHandler(array($this,\'checkToken\'));\n       $this->provider->setParam(\'__route__\', null);\n@@ -121,7 +121,7 @@ class Credential\n     if(!$cache)\n       $cache = array();\n     list($lastTimestamp, $nonces) = each($cache);\n-    if($provider->timestamp > (time()+300) || $provider->timestamp < $lastTimestamp) \n+    if($provider->timestamp > (time()+300) || $provider->timestamp < $lastTimestamp)\n     {\n       // timestamp can\'t be more then 30 seconds into the future\n       // or prior to the last timestamp\ndiff --git a/src/libraries/models/Group.php b/src/libraries/models/Group.php\nindex 1295c47d..1cb85def 100644\n--- a/src/libraries/models/Group.php\n+++ b/src/libraries/models/Group.php\n@@ -44,7 +44,7 @@ class Group\n   /**\n     * Get the next ID to be used for a action, group or photo.\n     * The ID is a base 32 string that represents an autoincrementing integer.\n-    * @return string \n+    * @return string\n     */\n   public static function getGroups($email = null)\n   {\ndiff --git a/src/libraries/models/ImageGraphicsMagick.php b/src/libraries/models/ImageGraphicsMagick.php\nindex adcf01f3..b3914e69 100644\n--- a/src/libraries/models/ImageGraphicsMagick.php\n+++ b/src/libraries/models/ImageGraphicsMagick.php\n@@ -20,7 +20,7 @@ class ImageGraphicsMagick implements ImageInterface\n     * Constructor which initializes the Gmagick object.\n     *\n     * @param string $filename Full path to the file which will be manipulated\n-    * @return void \n+    * @return void\n     */\n   public function __construct($filename)\n   {\n@@ -41,7 +41,7 @@ class ImageGraphicsMagick implements ImageInterface\n     * @param int $width Width of the resulting image\n     * @param int $height Height of the resulting image\n     * @param boolean $maintainAspectRatio When false it will crop to exact $width and $height else it will scale using "best fit"\n-    * @return void \n+    * @return void\n     */\n   public function scale($width, $height, $maintainAspectRatio = true)\n   {\n@@ -54,7 +54,7 @@ class ImageGraphicsMagick implements ImageInterface\n   /**\n     * Greyscale an image\n     *\n-    * @return void \n+    * @return void\n     */\n   public function greyscale()\n   {\n@@ -65,7 +65,7 @@ class ImageGraphicsMagick implements ImageInterface\n     * Save modifications to the image to the file system\n     *\n     * @param string $outputFile The file to write the modifications to.\n-    * @return void \n+    * @return void\n     */\n   public function write($outputFile)\n   {\ndiff --git a/src/libraries/models/ImageImageMagick.php b/src/libraries/models/ImageImageMagick.php\nindex 41d7cad0..4733af35 100644\n--- a/src/libraries/models/ImageImageMagick.php\n+++ b/src/libraries/models/ImageImageMagick.php\n@@ -20,7 +20,7 @@ class ImageImageMagick implements ImageInterface\n     * Constructor which initializes the Imagick object.\n     *\n     * @param string $filename Full path to the file which will be manipulated\n-    * @return void \n+    * @return void\n     */\n   public function __construct($filename)\n   {\n@@ -43,7 +43,7 @@ class ImageImageMagick implements ImageInterface\n     * @param int $width Width of the resulting image\n     * @param int $height Height of the resulting image\n     * @param boolean $maintainAspectRatio When false it will crop to exact $width and $height else it will scale using "best fit"\n-    * @return void \n+    * @return void\n     */\n   public function scale($width, $height, $maintainAspectRatio = true)\n   {\n@@ -56,7 +56,7 @@ class ImageImageMagick implements ImageInterface\n   /**\n     * Greyscale an image\n     *\n-    * @return void \n+    * @return void\n     */\n   public function greyscale()\n   {\n@@ -67,7 +67,7 @@ class ImageImageMagick implements ImageInterface\n     * Save modifications to the image to the file system\n     *\n     * @param string $outputFile The file to write the modifications to.\n-    * @return void \n+    * @return void\n     */\n   public function write($outputFile)\n   {\ndiff --git a/src/libraries/models/Photo.php b/src/libraries/models/Photo.php\nindex 6931ef8c..4bc9455f 100644\n--- a/src/libraries/models/Photo.php\n+++ b/src/libraries/models/Photo.php\n@@ -13,7 +13,7 @@ class Photo\n     * This deletes the original photo and all versions.\n     *\n     * @param string $id ID of the photo\n-    * @return boolean \n+    * @return boolean\n     */\n   public static function delete($id)\n   {\n@@ -33,7 +33,7 @@ class Photo\n     * @param int $width Width of the photo to generate\n     * @param int $height Height of the photo to generate\n     * @param string $options Options for the photo such as crop (CR) and greyscale (BW)\n-    * @return string \n+    * @return string\n     */\n   public static function generateCustomKey($width, $height, $options = null)\n   {\n@@ -47,7 +47,7 @@ class Photo\n     * @param int $width Width of the photo to generate\n     * @param int $height Height of the photo to generate\n     * @param string $options Options for the photo such as crop (CR) and greyscale (BW)\n-    * @return string \n+    * @return string\n     */\n   public static function generateFragment($width, $height, $options)\n   {\n@@ -63,7 +63,7 @@ class Photo\n     * The $options must start with a width and height (i.e. 800x600)\n     *\n     * @param string $options Options for the photo such as crop (CR) and greyscale (BW)\n-    * @return array \n+    * @return array\n     */\n   public static function generateFragmentReverse($options)\n   {\n@@ -82,7 +82,7 @@ class Photo\n     * @param string $param1 any parameter value\n     * ...\n     * @param string $paramN any parameter value\n-    * @return string \n+    * @return string\n     */\n   public static function generateHash(/*$args1, $args2, ...*/)\n   {\n@@ -101,7 +101,7 @@ class Photo\n     * These paths will also be the initial versions of the photo that are stored in the file system and database.\n     *\n     * @param string $photoName File name of the photo\n-    * @return array \n+    * @return array\n     */\n   public static function generatePaths($photoName)\n   {\n@@ -142,7 +142,7 @@ class Photo\n     * @param int $width The width of the requested photo.\n     * @param int $height The height of the requested photo.\n     * @param string $options Optional options to be applied on the photo\n-    * @return string \n+    * @return string\n     */\n   // TODO make private and called via an API in the photo controller\n   public static function generateUrlInternal($id, $width, $height, $options = null)\n@@ -209,7 +209,7 @@ class Photo\n     * Reads exif data from a photo.\n     *\n     * @param $photo Path to the photo.\n-    * @return array \n+    * @return array\n     */\n   public static function readExif($photo)\n   {\n@@ -226,8 +226,8 @@ class Photo\n       $dateTaken = @mktime($time[0], $time[1], $time[2], $date[1], $date[2], $date[0]);\n     }\n \n-    $exif_array = array(\'dateTaken\' => $dateTaken, \'width\' => $size[0], \n-      \'height\' => $size[1], \'cameraModel\' => @$exif[\'Model\'], \n+    $exif_array = array(\'dateTaken\' => $dateTaken, \'width\' => $size[0],\n+      \'height\' => $size[1], \'cameraModel\' => @$exif[\'Model\'],\n       \'cameraMake\' => @$exif[\'Make\'],\n       \'ISO\' => @$exif[\'ISOSpeedRatings\'],\n       \'exposureTime\' => @$exif[\'ExposureTime\']);\n@@ -386,7 +386,7 @@ class Photo\n         getLogger()->info("Photo ({$id}) successfully stored to the database");\n         return $id;\n       }\n-      else \n+      else\n       {\n         getLogger()->warn("Photo ({$id}) could NOT be stored to the database");\n         return false;\n@@ -424,7 +424,7 @@ class Photo\n   {\n     return array(\n       \'appId\' => getConfig()->get(\'application\')->appId,\n-      \'host\' => getFs()->getHost(), \n+      \'host\' => getFs()->getHost(),\n       \'views\' => 0,\n       \'status\' => 1,\n       \'permission\' => 0, // TODO\n@@ -439,7 +439,7 @@ class Photo\n     * @param $param2 One of the options\n     * ...\n     * @param $paramN One of the options\n-    * @return boolean \n+    * @return boolean\n     */\n   private static function isValidateHash(/*$hash, $args1, $args2, ...*/)\n   {\n@@ -454,7 +454,7 @@ class Photo\n     return (substr(sha1(implode(\'.\', $args)), 0, 5) == $hash);\n   }\n \n-  private static function frac2Num($frac) \n+  private static function frac2Num($frac)\n   {\n     $parts = explode(\'/\', $frac);\n \n@@ -470,10 +470,10 @@ class Photo\n     return floatval($parts[0]) / floatval($parts[1]);\n   }\n \n-  /*** GPS Utils \n-   * from http://stackoverflow.com/questions/2526304/php-extract-gps-exif-data \n+  /*** GPS Utils\n+   * from http://stackoverflow.com/questions/2526304/php-extract-gps-exif-data\n    **/\n-  private static function getGps($exifCoord, $hemi) \n+  private static function getGps($exifCoord, $hemi)\n   {\n     $degrees = count($exifCoord) > 0 ? self::frac2Num($exifCoord[0]) : 0;\n     $minutes = count($exifCoord) > 1 ? self::frac2Num($exifCoord[1]) : 0;\n@@ -489,7 +489,7 @@ class Photo\n     * Reads IPTC data from a photo.\n     *\n     * @param $photo Path to the photo.\n-    * @return array \n+    * @return array\n     */\n   private static function readIptc($photo)\n   {\n@@ -511,7 +511,7 @@ class Photo\n           $iptc_array[\'title\'] = $iptc[\'2#105\'][0];\n \telse if(isset($iptc[\'2#005\']))\n           $iptc_array[\'title\'] = $iptc[\'2#005\'][0];\n-\t\n+\n         if(isset($iptc[\'2#120\']))\n           $iptc_array[\'description\'] = $iptc[\'2#120\'][0];\n         if(isset($iptc[\'2#025\']))\ndiff --git a/src/libraries/models/Url.php b/src/libraries/models/Url.php\nindex 9584eddb..0ea1e964 100644\n--- a/src/libraries/models/Url.php\n+++ b/src/libraries/models/Url.php\n@@ -47,12 +47,12 @@ class Url\n     else\n       return Utility::returnValue(sprintf(\'/photos/%s/list\', $options), $write);\n   }\n-  \n+\n   public static function photoUpload($write = true)\n   {\n     return Utility::returnValue(\'/photos/upload\', $write);\n   }\n-  \n+\n   public static function photosUpload($write = true)\n   {\n     return Utility::returnValue(\'/photos/upload\', $write);\ndiff --git a/src/libraries/models/User.php b/src/libraries/models/User.php\nindex d693bf5c..73fcbda9 100644\n--- a/src/libraries/models/User.php\n+++ b/src/libraries/models/User.php\n@@ -37,7 +37,7 @@ class User\n   /**\n     * Get the email address of the logged in user.\n     *\n-    * @return string \n+    * @return string\n     */\n   public static function getEmailAddress()\n   {\n@@ -80,7 +80,7 @@ class User\n   {\n     $type = ucwords($type);\n     $key = "last{$type}Id";\n-    $user = self::getUserRecord();    \n+    $user = self::getUserRecord();\n     if($user === false)\n       return false;\n \ndiff --git a/src/libraries/models/Utility.php b/src/libraries/models/Utility.php\nindex 005fcb7b..fd4a8ea5 100644\n--- a/src/libraries/models/Utility.php\n+++ b/src/libraries/models/Utility.php\n@@ -233,19 +233,19 @@ class Utility\n     elseif($hours < 24)\n       return self::returnValue("{$prefix} {$hours} " . self::plural($hours, \'hour\', false) . " ago {$suffix}", $write);\n \n-    $days = intval($seconds / 86400);\n+    $days = intval(round($seconds / 86400));\n     if($days <= 7)\n       return self::returnValue("{$prefix} {$days} " . self::plural($days, \'day\', false) . " ago {$suffix}", $write);\n \n-    $weeks = intval($days / 7);\n+    $weeks = intval(round($days / 7));\n     if($weeks <= 4)\n       return self::returnValue("{$prefix} {$weeks} " . self::plural($weeks, \'week\', false) . " ago {$suffix}", $write);\n \n-    $months = intval($days / 30);\n+    $months = intval(round($days / 30));\n     if($months < 12)\n       return self::returnValue("{$prefix} {$months} " . self::plural($months, \'month\', false) . " ago {$suffix}", $write);\n \n-    $years = intval($days / 365);\n+    $years = intval(round($days / 365));\n     return self::returnValue("{$prefix} {$years} " . self::plural($years, \'year\', false) . " ago {$suffix}", $write);\n   }\n \ndiff --git a/src/libraries/models/Webhook.php b/src/libraries/models/Webhook.php\nindex 286d9518..b9b7c84d 100644\n--- a/src/libraries/models/Webhook.php\n+++ b/src/libraries/models/Webhook.php\n@@ -12,7 +12,7 @@ class Webhook\n     * Accepts a set of params that must include a type and targetType\n     *\n     * @param array $params Params describing the action to be added\n-    * @return mixed Action ID on success, false on failure \n+    * @return mixed Action ID on success, false on failure\n     */\n   public static function add($params)\n   {\ndiff --git a/src/templates/oauthCreate.php b/src/templates/oauthCreate.php\nindex 6f51c807..92be1009 100644\n--- a/src/templates/oauthCreate.php\n+++ b/src/templates/oauthCreate.php\n@@ -2,7 +2,7 @@\n   <form method="post">\n     <label>App Name</label>\n     <input type="text" name="name" placeholder="Enter a name">\n-    \n+\n     <!--<label>Permission</label>\n     <ul>\n       <li><input type="checkbox" name="permissions[]" value="read" class="checkbox" checked="true"> Read</li>\ndiff --git a/src/templates/settings.php b/src/templates/settings.php\nindex 4088f00e..a7c75e8f 100644\n--- a/src/templates/settings.php\n+++ b/src/templates/settings.php\n@@ -65,7 +65,7 @@\n \n   <label>Members</label>\n   <input type="text" placeholder="Email addresses of members (separate with commas)" value="" name="members">\n-  \n+\n   <button type="submit" class="group-update-click">Create a new group</button>\n </form>\n \n@@ -81,7 +81,7 @@\n \n           <label>Members</label>\n           <input type="text" value="<?php Utility::safe(implode(\',\', $group[\'members\'])); ?>" name="members">\n-          \n+\n           <button type="submit" class="group-update-click">Update</button>\n         </form><!--(<a href="/group/<?php echo $group[\'id\']; ?>/delete" class="group-delete-click">delete</a>)-->\n       </li>\ndiff --git a/src/tests/DatabaseSimpleDbTest.php b/src/tests/DatabaseSimpleDbTest.php\nindex fb106f03..6a1de93c 100644\n--- a/src/tests/DatabaseSimpleDbTest.php\n+++ b/src/tests/DatabaseSimpleDbTest.php\n@@ -332,7 +332,7 @@ class DatabaseSimpleDbTest extends PHPUnit_Framework_TestCase\n       ->will($this->returnValue(new AWSBatchSuccessResponse));\n     $db = getDb();\n     $db->inject(\'db\', $this->sdbStub);\n-    $res = $db->postTags(array(array(\'id\' => \'foo\'))); \n+    $res = $db->postTags(array(array(\'id\' => \'foo\')));\n     $this->assertTrue($res, \'The SimpleDb adapter did not return TRUE for postTags\');\n   }\n \n@@ -343,7 +343,7 @@ class DatabaseSimpleDbTest extends PHPUnit_Framework_TestCase\n       ->will($this->returnValue(new AWSBatchFailureResponse));\n     $db = getDb();\n     $db->inject(\'db\', $this->sdbStub);\n-    $res = $db->postTags(array(array(\'id\' => \'foo\'))); \n+    $res = $db->postTags(array(array(\'id\' => \'foo\')));\n     $this->assertFalse($res, \'The SimpleDb adapter did not return FALSE for postTags\');\n   }\n \n@@ -357,7 +357,7 @@ class DatabaseSimpleDbTest extends PHPUnit_Framework_TestCase\n       ->will($this->returnValue(new AWSBatchSuccessResponse));\n     $db = getDb();\n     $db->inject(\'db\', $this->sdbStub);\n-    $res = $db->postTagsCounter(array(\'foo0\' => 1, \'foo1\' => 2)); \n+    $res = $db->postTagsCounter(array(\'foo0\' => 1, \'foo1\' => 2));\n     $this->assertTrue($res, \'The SimpleDb adapter did not return TRUE for postTags\');\n   }\n \n@@ -368,7 +368,7 @@ class DatabaseSimpleDbTest extends PHPUnit_Framework_TestCase\n       ->will($this->returnValue(new AWSBatchFailureResponse));\n     $db = getDb();\n     $db->inject(\'db\', $this->sdbStub);\n-    $res = $db->postTags(array(\'tag\' => array(\'id\' => \'foo\'))); \n+    $res = $db->postTags(array(\'tag\' => array(\'id\' => \'foo\')));\n     $this->assertFalse($res, \'The SimpleDb adapter did not return FALSE for postTags\');\n   }\n \ndiff --git a/src/tests/helpers/aws.php b/src/tests/helpers/aws.php\nindex 6987ecef..222eecbd 100644\n--- a/src/tests/helpers/aws.php\n+++ b/src/tests/helpers/aws.php\n@@ -52,12 +52,12 @@ class AWSBatchSuccessResponse extends AWSSuccessResponse\n \n   public function create_domain()\n   {\n-    return new AWSSuccessResponse;    \n+    return new AWSSuccessResponse;\n   }\n \n   public function create_object()\n   {\n-    return new AWSSuccessResponse;    \n+    return new AWSSuccessResponse;\n   }\n \n   public function put_attributes()\n@@ -79,7 +79,7 @@ class AWSBatchSuccessResponse extends AWSSuccessResponse\n         $retval = array(new AWSPhotoMockSdb($this->count));\n         break;\n       default:\n-        $retval = new AWSSuccessResponse;    \n+        $retval = new AWSSuccessResponse;\n         break;\n     }\n     return $retval;\n@@ -100,7 +100,7 @@ class AWSBatchFailureResponse extends AWSFailureResponse\n \n   public function send()\n   {\n-    return new AWSFailureResponse;    \n+    return new AWSFailureResponse;\n   }\n \n   public function put_attributes()\n@@ -110,7 +110,7 @@ class AWSBatchFailureResponse extends AWSFailureResponse\n \n   public function create_object()\n   {\n-    return new AWSFailureResponse;    \n+    return new AWSFailureResponse;\n   }\n }\n \n', 'commit_subject': "Merge branch 'master' of github.com:openphoto/frontend", 'repo_name': 'photo/frontend', 'committer': {'name': 'Jaisen Mathai', 'email': '6f8c39689dd529cc34d5afb72b4666f3c1788f24@jmathai.com', 'time_sec': '1319951692', 'tz_offset': '-420', 'date': {'seconds': '1319951692'}}, 'commit_tree': 'af13a6ac501c9abf5adb81080c75c53aafa45ca7', 'commit_message': "Merge branch 'master' of github.com:openphoto/frontend\n", 'language_name': 'HTML', 'license': 'apache-2.0', 'hunks': '@@ -52,12 +52,12 @@ class AWSBatchSuccessResponse extends AWSSuccessResponse\n \n   public function create_domain()\n   {\n-    return new AWSSuccessResponse;    \n+    return new AWSSuccessResponse;\n   }\n \n   public function create_object()\n   {\n-    return new AWSSuccessResponse;    \n+    return new AWSSuccessResponse;\n   }\n \n   public function put_attributes()\n@@ -79,7 +79,7 @@ class AWSBatchSuccessResponse extends AWSSuccessResponse\n         $retval = array(new AWSPhotoMockSdb($this->count));\n         break;\n       default:\n-        $retval = new AWSSuccessResponse;    \n+        $retval = new AWSSuccessResponse;\n         break;\n     }\n     return $retval;\n@@ -100,7 +100,7 @@ class AWSBatchFailureResponse extends AWSFailureResponse\n \n   public function send()\n   {\n-    return new AWSFailureResponse;    \n+    return new AWSFailureResponse;\n   }\n \n   public function put_attributes()\n@@ -110,7 +110,7 @@ class AWSBatchFailureResponse extends AWSFailureResponse\n \n   public function create_object()\n   {\n-    return new AWSFailureResponse;    \n+    return new AWSFailureResponse;\n   }\n }\n \n', 'addition_count': 5, 'deletion_count': 5, 'src_file': 'a/src/tests/helpers/aws.php', 'tgt_file': 'b/src/tests/helpers/aws.php', 'file_extension': '.php', 'before_file': '<?php\nclass AmazonS3\n{\n  const ACL_PUBLIC = 1;\n  const ACL_PRIVATE = 1;\n  const REGION_US_E1 = 1;\n}\n\nclass CFPolicy\n{\n\n}\n\nclass AWSSuccessResponse\n{\n  public function isOK()\n  {\n    return true;\n  }\n\n  public function areOK()\n  {\n    return true;\n  }\n}\n\n\nclass AWSFailureResponse\n{\n  public $body;\n  public function __construct()\n  {\n    $this->body = new stdClass;\n    $this->body->Errors = array();\n  }\n\n  public function isOK()\n  {\n    return false;\n  }\n\n  public function areOK()\n  {\n    return false;\n  }\n}\n\nclass AWSBatchSuccessResponse extends AWSSuccessResponse\n{\n  private $type, $count;\n  public function __construct($type = null, $count = 0)\n\n  public function create_domain()\n  {\n    return new AWSSuccessResponse;    \n  }\n\n  public function create_object()\n  {\n    return new AWSSuccessResponse;    \n  }\n\n  public function put_attributes()\n    return true;\n  }\n\n  public function send()\n  {\n    return $this->returnByType();\n  }\n\n  public function create_domain()\n  {\n    return new AWSSuccessResponse;\n  }\n\n  public function create_object()\n  {\n        $retval = array(new AWSPhotoMockSdb($this->count));\n        break;\n      default:\n        $retval = new AWSSuccessResponse;    \n        break;\n    }\n    return $retval;\n\n  public function select()\n  {\n    return $this->returnByType();\n  }\n\n  private function returnByType()\n  {\n    $retval = null;\n    switch($this->type)\n    {\n      case \'photo\':\n        $retval = array(new AWSPhotoMockSdb($this->count));\n        break;\n\n  public function send()\n  {\n    return new AWSFailureResponse;    \n  }\n\n  public function put_attributes()\n\nclass AWSBatchFailureResponse extends AWSFailureResponse\n{\n\n  public function create_object()\n  {\n    return new AWSFailureResponse;    \n  }\n}\n\n    return new AWSFailureResponse;\n  }\n\n  public function send()\n  {\n    return new AWSFailureResponse;\n  }\n\n  public function put_attributes()\n  {\n    return false;\n  }\n\n  public function create_object()\n  {\n    return new AWSFailureResponse;\n  }\n}\n\nclass AWSCredentialMockSdb extends AWSSuccessResponse\n{\n  public $body;\n  public function __construct()\n  {\n    $this->body = new stdClass;\n    $this->body->SelectResult = new stdClass;\n    $this->body->SelectResult->Item = new stdClass;\n    $this->body->SelectResult->Item->Name = \'foo\';\n    $this->body->SelectResult->Item->Attribute = array(\n      $this->attr(\'name\', \'unittest\'),\n      $this->attr(\'clientSecret\', \'clientSecret\'),\n      $this->attr(\'userToken\', \'userToken\')\n    );\n\n  }\n\n  private function attr($name, $value)\n  {\n    $ret = new stdClass;\n    $ret->Name = $name;\n    $ret->Value = $value;\n    return $ret;\n  }\n}\n\nclass AWSGroupMockSdb extends AWSSuccessResponse\n{\n  public $body;\n  public function __construct($count = 1)\n  {\n    $this->body = new stdClass;\n    $this->body->SelectResult = new stdClass;\n    if($count == 1)\n    {\n      $this->body->SelectResult->Item = new stdClass;\n      $this->body->SelectResult->Item->Name = \'foo\';\n      $this->body->SelectResult->Item->Attribute = array(\n        $this->attr(\'name\', \'clientSecret\'),\n        $this->attr(\'members\', array(\'user@test.com\', \'foo@bar.com\'))\n      );\n    }\n    elseif($count > 1)\n    {\n      $this->body->SelectResult->Item = array();\n      for($i=0; $i<$count; $i++)\n      {\n        $this->body->SelectResult->Item[$i] = new stdClass;\n        $this->body->SelectResult->Item[$i]->Name = \'foo\';\n        $this->body->SelectResult->Item[$i]->Attribute = array(\n          $this->attr(\'name\', \'clientSecret\'),\n          $this->attr(\'members\', array(\'user@test.com\', \'foo@bar.com\'))\n        );\n      }\n    }\n  }\n\n  private function attr($name, $value)\n  {\n    $ret = new stdClass;\n    $ret->Name = $name;\n    $ret->Value = $value;\n    return $ret;\n  }\n}\n\nclass AWSPhotoMockSdb extends AWSSuccessResponse\n{\n  public $body;\n  public function __construct()\n  {\n    $this->body = new stdClass;\n    $this->body->SelectResult = new stdClass;\n    $this->body->SelectResult->Item = new stdClass;\n    $this->body->SelectResult->Item->Name = \'foo\';\n    $this->body->SelectResult->Item->Attribute = array(\n      $this->attr(\'host\', \'unittest\'),\n      $this->attr(\'dateTaken\', time())\n    );\n\n  }\n\n  private function attr($name, $value)\n  {\n    $ret = new stdClass;\n    $ret->Name = $name;\n    $ret->Value = $value;\n    return $ret;\n  }\n}\n\nclass AWSTagMockSdb extends AWSSuccessResponse\n{\n  public $body;\n  public function __construct($count = 1)\n  {\n    $this->body = new stdClass;\n    $this->body->SelectResult = new stdClass;\n    if($count == 1)\n    {\n      $this->body->SelectResult->Item = new stdClass;\n      $this->body->SelectResult->Item->Name = \'foo\';\n      $this->body->SelectResult->Item->Attribute = array(\n        $this->attr(\'count\', 1)\n      );\n    }\n    elseif($count > 1)\n    {\n      $this->body->SelectResult->Item = array();\n      for($i=0; $i<$count; $i++)\n      {\n        $this->body->SelectResult->Item[$i] = new stdClass;\n        $this->body->SelectResult->Item[$i]->Name = "foo{$i}";\n        $this->body->SelectResult->Item[$i]->Attribute = array(\n          $this->attr(\'count\', 1)\n        );\n      }\n    }\n  }\n\n  private function attr($name, $value)\n  {\n    $ret = new stdClass;\n    $ret->Name = $name;\n    $ret->Value = $value;\n    return $ret;\n  }\n}\n\nclass AWSUserMockSdb extends AWSSuccessResponse\n{\n  public $body;\n  public function __construct()\n  {\n    $this->body = new stdClass;\n    $this->body->SelectResult = new stdClass;\n    $this->body->SelectResult->Item = new stdClass;\n    $this->body->SelectResult->Item->Name = \'foo\';\n    $this->body->SelectResult->Item->Attribute = array(\n      $this->attr(\'lastPhotoId\', 1),\n      $this->attr(\'lastActionId\', 2),\n      $this->attr(\'version\', \'1.0.0\')\n    );\n  }\n\n  private function attr($name, $value)\n  {\n    $ret = new stdClass;\n    $ret->Name = $name;\n    $ret->Value = $value;\n    return $ret;\n  }\n}\n', 'message': "Merge branch 'master' of github.com:openphoto/frontend\n", 'author_name': 'Jaisen Mathai', 'lang': 'php'}