Skip to content

Commit 16bdd49

Browse files
committed
wip
1 parent c2c4fe6 commit 16bdd49

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

source/includes/write/transaction.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,11 @@
3434
$receipts->insertOne([
3535
'account_id' => $accountId,
3636
'description' => $summary,
37-
'timestamp' => new MongoDB\BSON\UTCDateTime((new DateTime())->getTimestamp()*1000),
38-
], ['session' => $session]);
37+
'timestamp' => new MongoDB\BSON\UTCDateTime(),
38+
],
39+
['session' => $session]);
3940

40-
echo 'Successfully performed transaction!\n';
41+
echo 'Successfully performed transaction!' , "\n";
4142
};
4243
// end-callback
4344

@@ -47,6 +48,6 @@
4748
try {
4849
MongoDB\with_transaction($session, $callback);
4950
} catch (Exception $e) {
50-
echo 'Caught exception: ', $e->getMessage(), '\n';
51+
echo 'Caught exception: ', $e->getMessage(), "\n";
5152
}
5253
// end-txn

source/write/transaction.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ completes the following actions:
124124
:language: console
125125
:visible: false
126126

127-
Successfully committed transaction!
127+
Successfully performed transaction!
128128

129129
Additional Information
130130
----------------------

0 commit comments

Comments
 (0)