Skip to content

Conversation

@lucafuser
Copy link

No description provided.

List of changes:
- Replaced protected properties with private properties in constructors for enhanced encapsulation.
- Updated constants to include the `string` type declaration for better clarity and type safety.
- Removed redundant constructor and action docblocks to clean up the codebase.
- Adjusted line formatting for improved readability.
List of changes:
- Updated the `DATE_FORMAT` constant to explicitly include the `string` type declaration.
- Removed redundant constructor docblocks to simplify and clean up the code.
- Improved code readability by adjusting formatting.
List of changes:
- Updated properties `$startTime` and `$endTime` to explicitly include `array` type declarations.
- Replaced untyped method parameters with `string` type hints for `start`, `end`, and `reset` methods to enhance type safety.
- Removed redundant constructor docblock for cleaner and simplified code.
List of changes:
- Added `#[\Override]` attribute to multiple `prepareDataSource` and other overridden methods for improved clarity on method overriding.
- Updated class `Browser` to implement `\Stringable`, ensuring compatibility with string conversion functionality.
- Refactored multiple properties in `Browser` class to include explicit type declarations (`string`, `?string`, `bool`) for enhanced type safety.
- Applied return type declarations (`: bool`, `: string`, `: void`) across numerous methods in the `Browser` class for better consistency and readability.
- Replaced occurrences of `strpos` with safer and more readable `str_contains` where applicable.
- Marked `Escaper` property in `StatusColumn` as `readonly` for improved immutability.
- Enhanced code readability by ensuring consistent formatting and reducing redundancies in several components.
List of changes:
- Updated `_construct` method in `Activity`, `Login`, `ActivityLogDetail`, and `ActivityLog` collection classes to include explicit `: void` return type declarations.
- Improved code consistency and type safety across the module.
List of changes:
- Updated `_construct` methods in `Activity`, `Login`, `ActivityLogDetail`, and `ActivityLog` resource model classes to include explicit `: void` return type declarations.
- Improved code consistency and type safety across resource model classes in the `AdminActivityLog` module.
List of changes:
- Updated return types in various methods (e.g., `getAdminDetails`, `getEditData`, `revertData`) to enhance type safety and consistency.
- Applied explicit type declarations to properties (e.g., `$labels` set to `private array`).
- Standardized parameter type hints and updated usages (e.g., replaced `$model->getId()` with `$model::class` for improved clarity).
- Ensured accurate type definitions for return types (e.g., `array{old_value: mixed, new_value: mixed}[]` added to `getEditData`).
- Improved readability by enforcing type constraints, including casting specific values to `string`.
…class

List of changes:
- Added return type declarations (`: bool`, `: void`, `: array`, `: string`, `: static`) across methods for enhanced type safety and consistency.
- Updated parameter type hints (e.g., `string $fullActionName`, `int $activityId`) to align with modern PHP typing standards.
- Replaced `Exception $e` with `Exception` in `catch` blocks, reducing redundancy.
- Updated `$model::class` usage for improved clarity when retrieving the model class name.
- Simplified conditional logic with null coalescing and ternary operators where applicable.
- Refactored PHPDoc comments by removing redundant or outdated annotations.
- Improved code formatting for better readability and maintainability.
List of changes:
- Added explicit parameter type hints (`string $path`, `string $module`) to `getConfigValue` and `getActivityModuleName` methods.
- Added return type declarations (`: array`, `: string`) to `getAllActions` and `getActivityModuleName` methods.
- Updated `isWildCardModel` to use `$model::class` for retrieving class name, enhancing readability and consistency.
- Improved overall type safety and aligned with modern PHP standards.
List of changes:
- Added explicit type casting to `$activityId` by casting it to `(int)` in the `revertActivity` method.
- Improved type safety and consistency in `MageOS\AdminActivityLog\Controller\Adminhtml\Activity\Revert`.
List of changes:
- Updated constants in `Status` class to include explicit `int` type declarations, enhancing type safety.
- Added type hints (`int`) to method parameters in `markSuccess` and `markFail`, improving input validation and consistency.
- Removed redundant PHPDoc comments for cleaner and more maintainable code.
- Simplified `load` method calls by removing unnecessary `(int)` casting of `$activityId`.
List of changes:
- Added `?JsonHelper` and `?DirectoryHelper` as optional dependencies in the `ActivityLogListing` constructor for enhanced flexibility.
- Updated method signatures to include explicit type declarations (e.g., `?array` for `getLogListing` and `array<string, string>` for `getAdminDetails`) for better type safety.
- Refactored `getAdminDetails` method to simplify the construction of return data using an associative array.
- Removed redundant PHPDoc comments to enhance code readability and maintainability.
- Applied modern PHP conventions, aligning with existing updates across the module.
List of changes:
- Removed unnecessary `@return string` PHPDoc comment from `getRevertUrl` method.
- Improved code readability and alignment with modern PHP practices by eliminating redundant annotations.
List of changes:
- Removed redundant constructor and method-level PHPDoc comments from `SaveAfter` and `SaveBefore` classes to enhance code clarity.
- Adjusted the placement of `benchmark->start` calls in `execute` methods for consistent and logical execution flow.
- Improved code readability by aligning with modern PHP conventions and removing unnecessary annotations.
List of changes:
- Replaced `protected readonly` properties with `private readonly` in constructors across observer classes for better access control and encapsulation.
- Removed redundant PHPDoc comments from constructors and execute methods in all observer classes to enhance code clarity and alignment with modern PHP conventions.
- Added explicit `string` type declaration for constants like `SYSTEM_CONFIG` and `ACTION_MASSCANCEL` in `SaveAfter` and `DeleteAfter` observers.
- Adjusted the order of `benchmark->start` calls within execute methods to ensure consistent and logical execution flow.
- Refactored redundant multi-line method call chaining into concise single-line calls for `loginRepository` in `LoginSuccess` and `LoginFailed` observers.
List of changes:
- Replaced `ActionInterface` with `AbstractAction` in method signatures for better alignment with Magento's action structure.
- Changed `protected readonly` properties to `private readonly` in the constructor to enhance encapsulation and access control.
- Removed redundant PHPDoc comments from the class and method declarations, adhering to modern PHP conventions.
- Streamlined method parameter names and usage to improve consistency and readability.
- Adjusted `beforeDispatch` method to use `$subject` instead of `$controller`, ensuring clarity and standardization in variable naming.
List of changes:
- Replaced `protected readonly` property in the constructor with `private readonly` for enhanced encapsulation.
- Updated method signature of `aroundDelete` to use `AbstractModel` for type safety and alignment with Magento conventions.
- Refactored redundant variable naming, replacing `$object` with `$user` for clarity and consistency.
- Removed unnecessary PHPDoc comments for cleaner and more maintainable code.
- Simplified method logic by aligning with modern PHP standards and removing repetitive calls.
List of changes:
- Replaced `protected readonly` properties in the constructor with `private readonly` to enhance encapsulation and access control.
- Removed redundant PHPDoc comments to improve code clarity and adhere to modern PHP conventions.
- Updated the `aroundLogout` method signature to include a `void` return type for better type safety.
- Removed unnecessary variable usage in `aroundLogout`, simplifying the method logic and aligning with modern PHP practices.
List of changes:
- Renamed `Action` to `ActionPlugin` to clarify its purpose as a plugin.
- Updated `Auth` to `AuthPlugin` and adjusted type usage in the `aroundLogout` method for improved alignment with naming conventions.
- Changed `Delete` to `DeletePlugin` for consistency with other plugin naming patterns.
- Updated `di.xml` to reflect the new class names in plugin declarations.
- Improved overall code clarity and maintained adherence to module structure and Magento standards.
List of changes:
- Replaced generic array type annotations with precise `array<string, mixed>` or `array<string, string>` declarations in constructors and methods across column classes.
- Added explicit property types (e.g., `array` and `string[]`) for better type safety, including constants such as `URL_COUNT` and `KEY_FIELD`.
- Removed redundant PHPDoc comments from constructors and method annotations to enhance code readability and align with modern PHP standards.
- Updated method signatures to use type-safe constructs, such as `array|string` instead of `string|array`, improving clarity in `ItemColumn` and similar classes.
- Applied `private readonly` for constructor dependencies wherever appropriate, following modern PHP practices for better encapsulation.
List of changes:
- Eliminated unnecessary PHPDoc comments from the `_construct` methods in resource model and collection classes across the `AdminActivityLog` module.
- Improved code readability and alignment with modern PHP standards by removing redundant annotations.
- Retained functionality while simplifying the codebase for better maintainability.
List of changes:
- Updated class constants to include explicit `string` type declarations for enhanced clarity and type enforcement.
- Refined method return types from `array` to `string[]` or more specific types where applicable for type safety.
- Enhanced method parameters with explicit type declarations, such as `string` and `DataObject`, improving code readability.
- Updated PHPDoc annotations for complex return types to better describe returned data structures.
- Simplified and modernized the constructor by using `protected readonly` properties for dependency injection.
- Removed redundancies and aligned code with modern PHP standards for improved maintainability.
List of changes:
- Removed redundant PHPDoc comments from the `SystemConfig` class constructor and methods to improve clarity.
- Updated method signatures by adding explicit parameter and return types for improved type safety, such as `DataObject` and typed array structures.
- Refined complex return type annotations for `getEditData` to clearly describe the data structure being returned.
- Simplified constructor using `protected readonly` dependencies for better maintainability and alignment with modern PHP practices.
- Enhanced overall readability and maintainability by adhering to current PHP standards.
List of changes:
- Replaced redundant `ValueFactory` with `ConfigCollectionFactory` for collection handling in theme configurations.
- Enhanced method signatures by adding precise parameter and return type declarations, such as `array<string, string>` for improved type safety.
- Updated `revertData` to utilize `Collection` for better type alignment and encapsulation.
- Removed unnecessary PHPDoc comments to simplify and align with modern PHP standards.
- Refactored constructor by using `protected readonly` properties, simplifying dependency injection and improving maintainability.
- Streamlined old data retrieval and processing logic with the updated collection factory.
List of changes:
- Added detailed return type annotations for `getEditData` to specify the exact structure of returned data, ensuring clarity and type safety.
- Updated method parameter `$fieldArray` in `getEditData` to use the `array` type for consistency and better type enforcement.
- Removed redundant PHPDoc comments for `getOldData` and `getEditData` methods, simplifying the interface while adhering to modern PHP standards.
List of changes:
- Updated the `initActivity` method in `Processor` class to include a precise return type `false|Activity`.
- Improved type safety and alignment with modern PHP standards.
List of changes:
- Updated the `getVersion` method to include a nullable `string` return type for enhanced type safety and clarity.
- Modified the `getAolVersion` method to specify a nullable `string` return type, improving adherence to modern PHP standards.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant