pathauto_cleanstring already removes forward slashes, with the (in this case) more efficient str_replace function.

This patch removes the two calls to preg_replace in the function pathauto_token_values when generating values for the taxonomy tokens [catpath] and [catpath-raw].

CommentFileSizeAuthor
pathauto-remove-preg_replace.patch983 bytesHugo Wetterberg

Comments

dave reid’s picture

Version: 6.x-1.1 » 6.x-1.x-dev
Status: Needs review » Reviewed & tested by the community

Confirmed, this is unnecessary as the cleanstring() function does this automatically.

greggles’s picture

Title: Seemingly unnecessary preg_replace in pathauto_token_values » Unnecessary preg_replace in pathauto_token_values
Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.