File tree Expand file tree Collapse file tree 3 files changed +9
-10
lines changed
Expand file tree Collapse file tree 3 files changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -4,5 +4,6 @@ composer.lock
44.php_cs.cache
55/vendor /
66update.bat
7+ test.bat
78.phpunit.result.cache
89todo.txt
Original file line number Diff line number Diff line change @@ -618,7 +618,14 @@ public function types()
618618 */
619619 public function typesAndWaits (float $ seconds )
620620 {
621- $ this ->getDriver ()->typesAndWaits ($ this ->message , $ seconds );
621+ $ driver = $ this ->getDriver ();
622+
623+ if (method_exists ($ driver , 'typesAndWaits ' )) {
624+ $ this ->getDriver ()->typesAndWaits ($ this ->message , $ seconds );
625+ } else {
626+ $ this ->types ();
627+ usleep ($ seconds * 1000000 );
628+ }
622629
623630 return $ this ;
624631 }
Original file line number Diff line number Diff line change @@ -74,15 +74,6 @@ public function hasMatchingEvent();
7474 */
7575 public function types (IncomingMessage $ matchingMessage );
7676
77- /**
78- * Send a typing indicator and wait for the given amount of seconds.
79- * @param IncomingMessage $matchingMessage
80- * @param int $seconds
81- * @param float $seconds
82- * @return mixed
83- */
84- public function typesAndWaits (IncomingMessage $ matchingMessage , float $ seconds );
85-
8677 /**
8778 * Tells if the stored conversation callbacks are serialized.
8879 *
You can’t perform that action at this time.
0 commit comments