File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -120,10 +120,8 @@ protected function boot() {
120120 * @return string
121121 */
122122 protected function parse_value ($ value ): string {
123- switch (true ) {
124- case $ value instanceof Carbon:
125- $ value = $ value ->format ($ this ->date_format );
126- break ;
123+ if ($ value instanceof Carbon) {
124+ $ value = $ value ->format ($ this ->date_format );
127125 }
128126
129127 return (string )$ value ;
@@ -189,7 +187,7 @@ protected function search(): Collection {
189187
190188 try {
191189 $ available_messages = $ this ->client ->getConnection ()->search ([$ this ->getRawQuery ()], $ this ->sequence );
192- return $ available_messages !== false ? new Collection ($ available_messages) : new Collection ( );
190+ return new Collection ($ available_messages );
193191 } catch (RuntimeException $ e ) {
194192 throw new GetMessagesFailedException ("failed to fetch messages " , 0 , $ e );
195193 } catch (ConnectionFailedException $ e ) {
You can’t perform that action at this time.
0 commit comments