- if (self::existsTable('verb') && !DBA::exists('verb', ['id' => 1])) {
- foreach (Item::ACTIVITIES as $index => $activity) {
- DBA::insert('verb', ['id' => $index + 1, 'name' => $activity], Database::INSERT_IGNORE);
+ if (self::existsTable('verb')) {
+ if (!DBA::exists('verb', ['id' => 1])) {
+ foreach (Item::ACTIVITIES as $index => $activity) {
+ DBA::insert('verb', ['id' => $index + 1, 'name' => $activity], Database::INSERT_IGNORE);
+ }
+ if ($verbose) {
+ echo "verb: activities added\n";
+ }
+ } elseif ($verbose) {
+ echo "verb: activities already added\n";