File tree Expand file tree Collapse file tree 3 files changed +9
-9
lines changed
Expand file tree Collapse file tree 3 files changed +9
-9
lines changed Original file line number Diff line number Diff line change 99final class Error implements NegativeOutcome
1010{
1111 private string $ id ;
12- private UnitOfError $ error ;
12+ private string $ error ;
1313
1414 public function __construct (string $ id , UnitOfError $ error )
1515 {
1616 $ this ->id = $ id ;
17- $ this ->error = $ error ;
17+ $ this ->error = serialize ( $ error) ;
1818 }
1919
2020 public function id (): string
@@ -24,6 +24,6 @@ public function id(): string
2424
2525 public function error (): UnitOfError
2626 {
27- return $ this ->error ;
27+ return unserialize ( $ this ->error ) ;
2828 }
2929}
Original file line number Diff line number Diff line change 99final class Result implements PositiveOutcome
1010{
1111 private string $ id ;
12- private UnitOfResult $ result ;
12+ private string $ result ;
1313
1414 public function __construct (string $ id , UnitOfResult $ result )
1515 {
1616 $ this ->id = $ id ;
17- $ this ->result = $ result ;
17+ $ this ->result = serialize ( $ result) ;
1818 }
1919
2020 public function id (): string
@@ -24,6 +24,6 @@ public function id(): string
2424
2525 public function result (): UnitOfResult
2626 {
27- return $ this ->result ;
27+ return unserialize ( $ this ->result ) ;
2828 }
2929}
Original file line number Diff line number Diff line change 1010final class Work implements Message
1111{
1212 private string $ id ;
13- private UnitOfWork $ work ;
13+ private string $ work ;
1414
1515 public function __construct (string $ id , UnitOfWork $ work )
1616 {
1717 $ this ->id = $ id ;
18- $ this ->work = $ work ;
18+ $ this ->work = serialize ( $ work) ;
1919 }
2020
2121 public function id (): string
@@ -25,6 +25,6 @@ public function id(): string
2525
2626 public function work (): UnitOfWork
2727 {
28- return $ this ->work ;
28+ return unserialize ( $ this ->work ) ;
2929 }
3030}
You can’t perform that action at this time.
0 commit comments