Skip to content

Wrong return type of Block Interface getId method #30721

Open
@peterlohaus

Description

@peterlohaus

Preconditions (*)

  1. Magento 2.4.0 Open Source
  2. Magento 2.4-develop

Steps to reproduce (*)

     /**
     * Get ID
     *
     * @return int|null
     */
    public function getId();

in src/vendor/magento/module-cms/Api/Data/BlockInterface.php

getId() returns a string.

Expected result (*)

\Magento\Cms\Model\Block::getId should cast the value to int before return

Actual result (*)

1.Return of string
image


Please provide Severity assessment for the Issue as Reporter. This information will help during Confirmation and Issue triage processes.

  • Severity: S0 - Affects critical data or functionality and leaves users without workaround.
  • Severity: S1 - Affects critical data or functionality and forces users to employ a workaround.
  • [ x ] Severity: S2 - Affects non-critical data or functionality and forces users to employ a workaround.
  • Severity: S3 - Affects non-critical data or functionality and does not force users to employ a workaround.
  • Severity: S4 - Affects aesthetics, professional look and feel, “quality” or “usability”.

Metadata

Metadata

Assignees

Labels

Issue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedPriority: P3May be fixed according to the position in the backlog.Progress: PR in progressReported on 2.4.0Indicates original Magento version for the Issue report.Reproduced on 2.4.xThe issue has been reproduced on latest 2.4-develop branchSeverity: S3Affects non-critical data or functionality and does not force users to employ a workaround.Triage: Dev.ExperienceIssue related to Developer Experience and needs help with Triage to Confirm or Reject it

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions