-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4c16672
commit f173a49
Showing
22 changed files
with
686 additions
and
605 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
44 changes: 44 additions & 0 deletions
44
src/integrations/groundhogg/helpers/groundhogg-helpers.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
<?php | ||
|
||
namespace Uncanny_Automator; | ||
|
||
/** | ||
* Class Groundhogg_Helpers | ||
* | ||
* @package Uncanny_Automator | ||
*/ | ||
class Groundhogg_Helpers { | ||
|
||
/** | ||
* Get all tags. | ||
* | ||
* @return array|mixed|void | ||
*/ | ||
public static function get_tag_options() { | ||
|
||
$tags = array(); | ||
$options = array(); | ||
|
||
try { | ||
$tags = \Groundhogg\get_db( 'tags' )->query( array() ); | ||
} catch ( \Error $e ) { | ||
automator_log( $e->getMessage(), $tags, AUTOMATOR_DEBUG_MODE, 'groundhogg' ); | ||
} catch ( \Exception $e ) { | ||
automator_log( $e->getMessage(), $tags, AUTOMATOR_DEBUG_MODE, 'groundhogg' ); | ||
} | ||
|
||
if ( empty( $tags ) ) { | ||
return $options; | ||
} | ||
|
||
foreach ( $tags as $tag ) { | ||
$options[] = array( | ||
'value' => $tag->tag_id, | ||
'text' => $tag->tag_name, | ||
); | ||
} | ||
|
||
return $options; | ||
} | ||
|
||
} |
This file was deleted.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.