Completed
Push — master ( 89c61c...e15fb0 )
by Guillermo A.
01:59
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.
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 Aws\DynamoDb\Marshaler;
6 6
 use Guillermoandrae\Db\DynamoDb\AttributeTypes;
@@ -33,24 +33,24 @@  discard block
 block discarded – undo
33 33
     ];
34 34
 
35 35
     if ($adapter->useTable($tableName)->createTable($keys)) {
36
-        printf("The '%s' table was successfully created!" . PHP_EOL, $tableName);
36
+        printf("The '%s' table was successfully created!".PHP_EOL, $tableName);
37 37
     }
38 38
 
39 39
     // list the created tables
40 40
     $tables = $adapter->listTables();
41 41
     foreach ($tables as $table) {
42
-        printf("The '%s' table exists!" . PHP_EOL, $table);
42
+        printf("The '%s' table exists!".PHP_EOL, $table);
43 43
     }
44 44
 
45 45
     // delete a table
46 46
     if ($adapter->useTable($tableName)->deleteTable()) {
47
-        printf("The '%s' table was successfully deleted!" . PHP_EOL, $tableName);
47
+        printf("The '%s' table was successfully deleted!".PHP_EOL, $tableName);
48 48
     }
49 49
 
50 50
     // check for the existence of a table
51 51
     if (!$adapter->useTable($tableName)->tableExists()) {
52
-        printf("The '%s' table no longer exists!" . PHP_EOL, $tableName);
52
+        printf("The '%s' table no longer exists!".PHP_EOL, $tableName);
53 53
     }
54
-} catch(\Exception $ex) {
54
+} catch (\Exception $ex) {
55 55
     die($ex->getMessage());
56 56
 }
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 Aws\DynamoDb\Marshaler;
6 6
 use Guillermoandrae\Db\DynamoDb\AttributeTypes;
@@ -40,15 +40,15 @@  discard block
 block discarded – undo
40 40
             'year' => 1984,
41 41
             'single' => 'Nightshift'
42 42
         ]);
43
-        printf("Successfully added '%s' to the '%s' table!" . PHP_EOL, $name, $tableName);
43
+        printf("Successfully added '%s' to the '%s' table!".PHP_EOL, $name, $tableName);
44 44
     }
45 45
 
46 46
     // get all items
47 47
     $items = $adapter->useTable($tableName)->findAll();
48
-    printf("The following items were found in the '%s' table:" . PHP_EOL, $tableName);
48
+    printf("The following items were found in the '%s' table:".PHP_EOL, $tableName);
49 49
     foreach ($items as $item) {
50 50
         printf(
51
-            "\t - '%s', who died in '%s'" . PHP_EOL,
51
+            "\t - '%s', who died in '%s'".PHP_EOL,
52 52
             $item['name'],
53 53
             $item['year'],
54 54
             $tableName
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
         'year' => 1984
62 62
     ]);
63 63
     printf(
64
-        "Successfully retrieved '%s' (mentioned in the Commodores' tribute single '%s') from the '%s' table!" . PHP_EOL,
64
+        "Successfully retrieved '%s' (mentioned in the Commodores' tribute single '%s') from the '%s' table!".PHP_EOL,
65 65
         $item['name'],
66 66
         $item['single'],
67 67
         $tableName
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
     // delete an item
71 71
     if ($adapter->useTable($tableName)->delete(['name' => 'Marvin Gaye', 'year' => 1984])) {
72 72
         printf(
73
-            "Successfully deleted '%s' from the '%s' table!" . PHP_EOL,
73
+            "Successfully deleted '%s' from the '%s' table!".PHP_EOL,
74 74
             $item['name'],
75 75
             $tableName
76 76
         );
@@ -78,10 +78,10 @@  discard block
 block discarded – undo
78 78
 
79 79
     // get all items
80 80
     $items = $adapter->useTable($tableName)->findAll();
81
-    printf("The following items remain in the '%s' table:" . PHP_EOL, $tableName);
81
+    printf("The following items remain in the '%s' table:".PHP_EOL, $tableName);
82 82
     foreach ($items as $item) {
83 83
         printf(
84
-            "\t - '%s', who died in '%s'" . PHP_EOL,
84
+            "\t - '%s', who died in '%s'".PHP_EOL,
85 85
             $item['name'],
86 86
             $item['year'],
87 87
             $tableName
Please login to merge, or discard this patch.