Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Issues with isset, empty and unset on DBObject properties #8

Closed
djrobe opened this Issue · 1 comment

2 participants

@djrobe

Calls to empty() or isset() on a DBObject property always returns true, and unset() has no effect as the magic methods __isset and __unset are not defined. The following methods need to be added:

          public function __isset($key) {
              return array_key_exists($key, $this->columns);
          }


          public function __unset($key) {
              unset($this->columns[$key]);
          }
@tylerhall
Owner

Thanks for that! I've updated the class with the methods you supplied.

@tylerhall tylerhall closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.