slug = $slug; $this->name = $name; new Charitable_Template( $this->get_template_names(), true, false ); } /** * Returns the array of template names. * * @since 1.0.0 * * @return array */ private function get_template_names() { $names = array( $this->slug . '.php' ); /** * If a name is set, add the slug-name.php combination to the start of the $names array */ if ( strlen( $this->name ) ) { array_unshift( $names, $this->slug . '-' . $this->name . '.php' ); } return $names; } } endif;