Commit f79a1a73 authored by Dries's avatar Dries
Browse files

- Patch #744258 by sun, jpmckinney, catch: admin/structure/taxonomy paths have...

- Patch #744258 by sun, jpmckinney, catch: admin/structure/taxonomy paths have to use machine_name(), not vid.
parent 77c0c78d
...@@ -159,6 +159,9 @@ function taxonomy_schema() { ...@@ -159,6 +159,9 @@ function taxonomy_schema() {
'indexes' => array( 'indexes' => array(
'list' => array('weight', 'name'), 'list' => array('weight', 'name'),
), ),
'unique keys' => array(
'machine_name' => array('machine_name'),
),
); );
$schema['taxonomy_index'] = array( $schema['taxonomy_index'] = array(
...@@ -256,6 +259,7 @@ function taxonomy_update_7002() { ...@@ -256,6 +259,7 @@ function taxonomy_update_7002() {
); );
db_add_field('taxonomy_vocabulary', 'machine_name', $field); db_add_field('taxonomy_vocabulary', 'machine_name', $field);
db_add_unique_key('taxonomy_vocabulary', 'machine_name', array('machine_name'));
foreach (taxonomy_get_vocabularies() as $vid => $vocabulary) { foreach (taxonomy_get_vocabularies() as $vid => $vocabulary) {
$machine_name = 'vocabulary_' . $vid; $machine_name = 'vocabulary_' . $vid;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment