You are here

function sitemap_vocab_depth_update in Sitemap 2.0.x

Same name and namespace in other branches
  1. 8.2 sitemap.install \sitemap_vocab_depth_update()

Helper function to update the term_depth setting.

Parameters

int $value:

Return value

int

1 call to sitemap_vocab_depth_update()
sitemap_update_8200 in ./sitemap.install
Update configuration for 2.x.

File

./sitemap.install, line 212
Installation functions for Sitemap module.

Code

function sitemap_vocab_depth_update($value) {
  if ($value == -1 || $value > Vocabulary::DEPTH_MAX) {
    return Vocabulary::DEPTH_MAX;
  }
  return $value;
}