function word_link_disable_invalid_word_action in Word Link 7.2
Action function.
Checks if word URL is valid and if not change word status to disabled.
File
- ./
word_link.actions.inc, line 204 - Actions for the Word Link module.
Code
function word_link_disable_invalid_word_action($word, &$context) {
if (!word_link_valid_path(drupal_get_normal_path($word->url))) {
$word->status = FALSE;
word_link_save($word);
}
if ($context['progress']['current'] >= $context['progress']['total']) {
word_link_clear_filter_cache();
}
}