Completed
Push — master ( 3890f4...ffa1fa )
by Guillermo A.
03:24
created
src/Db/DynamoDb/DynamoDbAdapter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@
 block discarded – undo
57 57
         } catch (DynamoDbException $ex) {
58 58
             throw new DbException($ex->getMessage());
59 59
         } catch (InvalidArgumentException $ex) {
60
-            throw new DbException('Bad key schema: ' . $ex->getMessage());
60
+            throw new DbException('Bad key schema: '.$ex->getMessage());
61 61
         }
62 62
     }
63 63
 
Please login to merge, or discard this patch.
src/Db/DynamoDb/QueryRequest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
     {
21 21
         $sortKeyConditionExpression = $this->parseExpression($operator, $keyName);
22 22
         $this->addExpressionAttributeValue($keyName, $value);
23
-        $this->keyConditionExpression .= ' AND ' . $sortKeyConditionExpression;
23
+        $this->keyConditionExpression .= ' AND '.$sortKeyConditionExpression;
24 24
         return $this;
25 25
     }
26 26
 
Please login to merge, or discard this patch.
examples/items.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-require dirname(__DIR__) . '/vendor/autoload.php';
3
+require dirname(__DIR__).'/vendor/autoload.php';
4 4
 
5 5
 use Guillermoandrae\Db\DynamoDb\AttributeTypes;
6 6
 use Guillermoandrae\Db\DynamoDb\DynamoDbAdapter;
@@ -32,15 +32,15 @@  discard block
 block discarded – undo
32 32
             'year' => 1984,
33 33
             'single' => 'Nightshift'
34 34
         ]);
35
-        printf("Successfully added '%s' to the '%s' table!" . PHP_EOL, $name, $tableName);
35
+        printf("Successfully added '%s' to the '%s' table!".PHP_EOL, $name, $tableName);
36 36
     }
37 37
 
38 38
     // get all items
39 39
     $items = $adapter->useTable($tableName)->findAll();
40
-    printf("The following items were found in the '%s' table:" . PHP_EOL, $tableName);
40
+    printf("The following items were found in the '%s' table:".PHP_EOL, $tableName);
41 41
     foreach ($items as $item) {
42 42
         printf(
43
-            "\t - '%s', who died in '%s'" . PHP_EOL,
43
+            "\t - '%s', who died in '%s'".PHP_EOL,
44 44
             $item['name'],
45 45
             $item['year'],
46 46
             $tableName
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
         'year' => 1984
54 54
     ]);
55 55
     printf(
56
-        "Successfully retrieved '%s' (mentioned in the Commodores' tribute single '%s') from the '%s' table!" . PHP_EOL,
56
+        "Successfully retrieved '%s' (mentioned in the Commodores' tribute single '%s') from the '%s' table!".PHP_EOL,
57 57
         $item['name'],
58 58
         $item['single'],
59 59
         $tableName
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
     // delete an item
63 63
     if ($adapter->useTable($tableName)->delete(['name' => 'Marvin Gaye', 'year' => 1984])) {
64 64
         printf(
65
-            "Successfully deleted '%s' from the '%s' table!" . PHP_EOL,
65
+            "Successfully deleted '%s' from the '%s' table!".PHP_EOL,
66 66
             $item['name'],
67 67
             $tableName
68 68
         );
@@ -70,10 +70,10 @@  discard block
 block discarded – undo
70 70
 
71 71
     // get all items
72 72
     $items = $adapter->useTable($tableName)->findAll();
73
-    printf("The following items remain in the '%s' table:" . PHP_EOL, $tableName);
73
+    printf("The following items remain in the '%s' table:".PHP_EOL, $tableName);
74 74
     foreach ($items as $item) {
75 75
         printf(
76
-            "\t - '%s', who died in '%s'" . PHP_EOL,
76
+            "\t - '%s', who died in '%s'".PHP_EOL,
77 77
             $item['name'],
78 78
             $item['year'],
79 79
             $tableName
Please login to merge, or discard this patch.
examples/tables.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-require dirname(__DIR__) . '/vendor/autoload.php';
3
+require dirname(__DIR__).'/vendor/autoload.php';
4 4
 
5 5
 use Guillermoandrae\Db\DynamoDb\AttributeTypes;
6 6
 use Guillermoandrae\Db\DynamoDb\DynamoDbAdapter;
@@ -25,25 +25,25 @@  discard block
 block discarded – undo
25 25
     ];
26 26
 
27 27
     if ($adapter->useTable($tableName)->createTable($keys)) {
28
-        printf("The '%s' table was successfully created!" . PHP_EOL, $tableName);
28
+        printf("The '%s' table was successfully created!".PHP_EOL, $tableName);
29 29
     }
30 30
 
31 31
     // list the created tables
32 32
     $tables = $adapter->listTables();
33 33
     foreach ($tables as $table) {
34
-        printf("The '%s' table exists!" . PHP_EOL, $table);
34
+        printf("The '%s' table exists!".PHP_EOL, $table);
35 35
     }
36 36
 
37 37
     // delete a table
38 38
     if ($adapter->useTable($tableName)->deleteTable()) {
39
-        printf("The '%s' table was successfully deleted!" . PHP_EOL, $tableName);
39
+        printf("The '%s' table was successfully deleted!".PHP_EOL, $tableName);
40 40
     }
41 41
 
42 42
     // check for the existence of a table
43 43
     if (!$adapter->useTable($tableName)->tableExists()) {
44
-        printf("The '%s' table no longer exists!" . PHP_EOL, $tableName);
44
+        printf("The '%s' table no longer exists!".PHP_EOL, $tableName);
45 45
     }
46 46
 
47
-} catch(\Exception $ex) {
47
+} catch (\Exception $ex) {
48 48
     die($ex->getMessage());
49 49
 }
Please login to merge, or discard this patch.