Skip to content

Commit 5117921

Browse files
committed
CMR-9332: Fix lint issues for ACL libs
This commit addresses lint errors and warnings in ACL-related files, improving code quality and consistency. The changes include: 1. Naming convention updates: - Changed 'acl_core' to 'acl-core' in: - access-control-app/src/cmr/access_control/api/routes.clj - acl-lib/src/cmr/acl/core.clj - acl-lib/test/cmr/acl/test/core_test.clj 2. Functional changes: a. access-control-app/src/cmr/access_control/api/routes.clj: - Refactored `search-for-groups` for better readability - In `get-permissions`: - Changed `(= 0 page-size)` to `(zero? page-size)` - Changed `(> valid-upper-bound 0)` to `(pos? valid-upper-bound)` b. access-control-app/src/cmr/access_control/services/acl_validation.clj: - Changed `(not (some #{provider-id} ...))` to `(not-any? #{provider-id} ...)` c. access-control-app/src/cmr/access_control/test/util.clj: - Simplified provider-id assignment using `or` d. acl-lib/src/cmr/acl/core.clj: - Refactored `context->sids` for better readability - Improved error handling in `get-permitting-acls` 3. Test file improvements: a. acl-lib/test/cmr/acl/test/acl_fetcher_test.clj: - Updated mock functions to use underscore prefix for unused params b. acl-lib/test/cmr/acl/test/core_test.clj: - Updated mock functions to use underscore prefix for unused params - Adjusted tests to reflect naming convention changes 4. General code style improvements: - Consistent use of kebab-case for Clojure naming conventions - Removed redundant code and simplified expressions - Improved function call structures for better readability
1 parent f17c748 commit 5117921

File tree

7 files changed

+368
-365
lines changed

7 files changed

+368
-365
lines changed

0 commit comments

Comments
 (0)