From bbf15ab9f1d9acb8c6d05b07c974c7c1af9587ae Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Mon, 8 May 2017 20:17:57 +1200 Subject: [PATCH] Allow type override in FormAction --- src/Forms/FormAction.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Forms/FormAction.php b/src/Forms/FormAction.php index 588f46168..0cc5985d8 100644 --- a/src/Forms/FormAction.php +++ b/src/Forms/FormAction.php @@ -175,7 +175,11 @@ class FormAction extends FormField public function getAttributes() { - $type = (isset($this->attributes['src'])) ? 'image' : 'submit'; + if (isset($this->attributes['type'])) { + $type = $this->attributes['type']; + } else { + $type = (isset($this->attributes['src'])) ? 'image' : 'submit'; + } return array_merge( parent::getAttributes(),