Allow to chaining calls in setSubmitDestructive
authorSethakill <sethakill@outlook.com>
Wed, 18 May 2016 16:38:16 +0000 (18:38 +0200)
committerSethakill <sethakill@outlook.com>
Wed, 18 May 2016 16:38:16 +0000 (18:38 +0200)
and setSubmitProgressive.

Change-Id: I926fa717edf146c64bb7e5287f9dc051e30f6566

includes/htmlform/HTMLForm.php

index 0dab3bb..e891c9c 100644 (file)
@@ -1226,17 +1226,25 @@ class HTMLForm extends ContextSource {
        /**
         * Identify that the submit button in the form has a destructive action
         * @since 1.24
+        *
+        * @return HTMLForm $this for chaining calls (since 1.28)
         */
        public function setSubmitDestructive() {
                $this->mSubmitFlags = [ 'destructive', 'primary' ];
+
+               return $this;
        }
 
        /**
         * Identify that the submit button in the form has a progressive action
         * @since 1.25
+        *
+        * @return HTMLForm $this for chaining calls (since 1.28)
         */
        public function setSubmitProgressive() {
                $this->mSubmitFlags = [ 'progressive', 'primary' ];
+
+               return $this;
        }
 
        /**