X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/febc815b2c9d85be5717da9e8d164bd2daa97e31..16e7b37c7914d753890c1a05a9335f3b43751eb8:/wp-includes/class-wp-dependency.php diff --git a/wp-includes/class-wp-dependency.php b/wp-includes/class-wp-dependency.php new file mode 100644 index 00000000..92c54561 --- /dev/null +++ b/wp-includes/class-wp-dependency.php @@ -0,0 +1,104 @@ +handle, $this->src, $this->deps, $this->ver, $this->args ) = func_get_args(); + if ( ! is_array($this->deps) ) + $this->deps = array(); + } + + /** + * Add handle data. + * + * @access public + * @since 2.6.0 + * + * @param string $name The data key to add. + * @param mixed $data The data value to add. + * @return bool False if not scalar, true otherwise. + */ + public function add_data( $name, $data ) { + if ( !is_scalar($name) ) + return false; + $this->extra[$name] = $data; + return true; + } + +}