Skip to content

Commit

Permalink
Fixed bug that wasn't sending the instance to the confirmation messag…
Browse files Browse the repository at this point in the history
…e function
  • Loading branch information
Gustavinho committed Jun 24, 2021
1 parent 5889441 commit ad7fb7c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
6 changes: 1 addition & 5 deletions src/Actions/Action.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,6 @@ private function setMessage($type = 'success', $message = null)

public function shouldBeConfirmed()
{
if (method_exists($this, 'getConfirmationMessage')) {
return !empty($this->getConfirmationMessage(null));
}

return false;
return method_exists($this, 'getConfirmationMessage');
}
}
2 changes: 2 additions & 0 deletions tests/Feature/ExecuteActionsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ public function testSeeConfirmationMessage()
]);
}

// TODO: test custom confirmation message

public function testCallActionAfterConfirmationMessage()
{
$user = factory(UserTest::class)->create();
Expand Down

0 comments on commit ad7fb7c

Please sign in to comment.