From b47177d4bbd316b1e6522e7341567ec54c2590f9 Mon Sep 17 00:00:00 2001 From: Steve Boyd Date: Fri, 11 Nov 2022 12:11:08 +1300 Subject: [PATCH] ENH Use HashNameObfuscator in dev environments --- _config/config.yml | 11 +---------- src/Schema/Storage/HashNameObfuscator.php | 2 +- src/Schema/Storage/NameObfuscator.php | 2 +- 3 files changed, 3 insertions(+), 12 deletions(-) diff --git a/_config/config.yml b/_config/config.yml index 86a1488c..0ab55625 100644 --- a/_config/config.yml +++ b/_config/config.yml @@ -33,7 +33,7 @@ SilverStripe\Core\Injector\Injector: storeCreator: '%$SilverStripe\GraphQL\Schema\Interfaces\SchemaStorageCreator' SilverStripe\GraphQL\Schema\Storage\NameObfuscator: - class: SilverStripe\GraphQL\Schema\Storage\HybridObfuscator + class: SilverStripe\GraphQL\Schema\Storage\HashNameObfuscator SilverStripe\GraphQL\Schema\Schema: schemas: [] @@ -61,12 +61,3 @@ Only: SilverStripe\Core\Injector\Injector: SilverStripe\GraphQL\Schema\Storage\NameObfuscator: class: SilverStripe\GraphQL\Schema\Storage\NaiveNameObfuscator - ---- -Name: graphqlconfig-live -Except: - environment: dev ---- -SilverStripe\Core\Injector\Injector: - SilverStripe\GraphQL\Schema\Storage\NameObfuscator: - class: SilverStripe\GraphQL\Schema\Storage\HashNameObfuscator diff --git a/src/Schema/Storage/HashNameObfuscator.php b/src/Schema/Storage/HashNameObfuscator.php index 793e8f38..6d54577c 100644 --- a/src/Schema/Storage/HashNameObfuscator.php +++ b/src/Schema/Storage/HashNameObfuscator.php @@ -4,7 +4,7 @@ namespace SilverStripe\GraphQL\Schema\Storage; /** - * For the most obscure approach, hash the file names so they're completely undiscoverable. + * For the most obscure approach, hash the file names so they're highly undiscoverable in IDE search */ class HashNameObfuscator implements NameObfuscator { diff --git a/src/Schema/Storage/NameObfuscator.php b/src/Schema/Storage/NameObfuscator.php index bcaa6210..3e9a4140 100644 --- a/src/Schema/Storage/NameObfuscator.php +++ b/src/Schema/Storage/NameObfuscator.php @@ -4,7 +4,7 @@ namespace SilverStripe\GraphQL\Schema\Storage; /** - * Defines a service that can obfuscate classnames to make their files less discoverable + * Defines a service that can obfuscate classnames to make their files less discoverable in IDE Search */ interface NameObfuscator {