src/Modal.php
public function set($fx = [], $arg2 = null)
    {
        if (!is_object($fx) && !($fx instanceof Closure)) {
            throw new Exception('Error: Need to pass a function to Modal::set()');
        }
        $this->fx = [$fx];
        $this->enableCallback();

        return $this;
    }
public function set($fx = [], $arg2 = null)
    {
        if (!is_object($fx) && !($fx instanceof Closure)) {
            throw new Exception('Error: Need to pass a function to Modal::set()');
        }
        $this->fx = [$fx];
        $this->enableCallback();

        return $this;
    }
public function set ( $ fx = [ ] , $ arg2 = null ) { if ( ! is_object ( $ fx ) && ! ( $ fx instanceof Closure ) ) { throw new Exception ( 'Error: Need to pass a function to Modal::set()' ) ; } $ this -> fx = [ $ fx ] ; $ this -> enableCallback ( ) ; return $ this ; }
Set callback function for this modal.

@param array|string $fx
@param array|string $arg2

@throws Exception

@return $this
Set callback function for this modal .