Skip to content

Commit

Permalink
Re-added EasySlugger to fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
snipe committed Apr 22, 2020
1 parent 1c5486e commit 5dc64ea
Show file tree
Hide file tree
Showing 3 changed files with 261 additions and 266 deletions.
4 changes: 2 additions & 2 deletions app/Models/CustomField.php
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ public function isFieldDecryptable($string)
*
* @author [A. Gianotto] [<snipe@snipe.net>]
* @since [v3.4]
* @return boolean
* @return string
*/
public function convertUnicodeDbSlug($original = null)
{
Expand All @@ -336,7 +336,7 @@ public function convertUnicodeDbSlug($original = null)
if (!function_exists('transliterator_transliterate')) {
$long_slug = '_snipeit_' . str_slug(\Patchwork\Utf8::utf8_encode(trim($name)), '_');
} else {
$long_slug = '_snipeit_' . str_slug($name, '_');
$long_slug = '_snipeit_' . Utf8Slugger::slugify($name, '_');
}

return substr($long_slug, 0, 50) . '_' . $id;
Expand Down
3 changes: 3 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
"fideloper/proxy": "^4.3",
"guzzlehttp/guzzle": "^6.5",
"intervention/image": "^2.5",
"javiereguiluz/easyslugger": "^1.0",
"laravel/framework": "^6.0",
"laravel/helpers": "^1.2",
"laravel/passport": "^8.4",
Expand All @@ -58,6 +59,8 @@
},
"require-dev": {
"codeception/codeception": "^4.1",
"codeception/module-asserts": "^1.2",
"codeception/module-laravel5": "^1.1",
"fzaninotto/faker": "^1.9",
"phpunit/php-token-stream": "^3.1",
"phpunit/phpunit": "^8.5",
Expand Down
Loading

0 comments on commit 5dc64ea

Please sign in to comment.