v1.18.x
barisusakli 9 years ago
parent e067d26ca3
commit 9981555042

@ -218,13 +218,13 @@ module.exports = function(Groups) {
}); });
} }
function checkNameChange(oldName, newName, callback) { function checkNameChange(currentName, newName, callback) {
if (oldName === newName) { if (currentName === newName) {
return callback(); return callback();
} }
var oldSlug = utils.slugify(oldName); var currentSlug = utils.slugify(currentName);
var newSlug = utils.slugify(newName); var newSlug = utils.slugify(newName);
if (oldSlug === newSlug) { if (currentSlug === newSlug) {
return callback(); return callback();
} }
Groups.existsBySlug(newSlug, function(err, exists) { Groups.existsBySlug(newSlug, function(err, exists) {

Loading…
Cancel
Save