Skip to content

Instantly share code, notes, and snippets.

@nickstewart95
Created May 27, 2020 00:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nickstewart95/31557338ffe67bd375cf105b0a017fdc to your computer and use it in GitHub Desktop.
Save nickstewart95/31557338ffe67bd375cf105b0a017fdc to your computer and use it in GitHub Desktop.
protected function setupCategories() {
$categories = Category::where('taxonomy', 'category')->get();
foreach($categories as $category) {
$data = $category->createObject();
array_push($this->dataObject, $data);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment