CommentFileSizeAuthor
#2 3349518-2.patch756 bytessamitk
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

samit.310@gmail.com created an issue. See original summary.

samitk’s picture

Assigned: samitk » Unassigned
Status: Needs work » Needs review
StatusFileSize
new756 bytes

Above warning has been fixed.

Rassoni made their first commit to this issue’s fork.

rassoni’s picture

Title: Drupal Coding Standards Issues | phpcs » Fix the issues reported by phpcs
Priority: Normal » Minor
Issue tags: -Coding standards Phpcs, -Phpcs Drupal coding standard issue
hardikpandya’s picture

Status: Needs review » Needs work

RTBC for the patch provided by @samit.310@gmail.com. The MR removes the comment entirely which is inappropriate and hence marking this as Needs Work.

rassoni’s picture

@hardikpandya I have removed the code because the code is commented.

Commented out code should be simply removed.

PHPCS throw commented code issue which is unnecessary.

avpaderno’s picture

Status: Needs work » Needs review

The MR is correct: Commented out code should be removed, except in the case the code is planned to be re-added, but in that case there should be a @todo comment saying that.

a.aaronjake’s picture

Status: Needs review » Needs work

Hi @Rassoni,

I have applied the changes you committed on MR!2, some errors were still reported. Please see below:

➜  content_moderation_node_grants git:(1.0.x) curl https://git.drupalcode.org/project/content_moderation_node_grants/-/merge_requests/2.diff | patch -p1
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   881    0   881    0     0   3029      0 --:--:-- --:--:-- --:--:--  3157
patching file src/Plugin/views/filter/UpdatableFilter.php
➜  content_moderation_node_grants git:(1.0.x) ✗ ..
➜  contrib git:(main) ✗ phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml,twig content_moderation_node_grants

FILE: /Users/PrometInterns/Demo-site/drupal-orgissue/web/modules/contrib/content_moderation_node_grants/content_moderation_node_grants.module
---------------------------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
---------------------------------------------------------------------------------------------------------------------------------------------
 11 | ERROR | [x] Use statements should be sorted alphabetically. The first wrong one is Drupal\Component\Utility\Html.
---------------------------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
---------------------------------------------------------------------------------------------------------------------------------------------


FILE: /Users/PrometInterns/Demo-site/drupal-orgissue/web/modules/contrib/content_moderation_node_grants/content_moderation_node_grants.node_grants.inc
------------------------------------------------------------------------------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
------------------------------------------------------------------------------------------------------------------------------------------------------
 13 | ERROR | [x] Use statements should be sorted alphabetically. The first wrong one is Drupal\Core\Session\AccountInterface.
------------------------------------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
------------------------------------------------------------------------------------------------------------------------------------------------------

Time: 224ms; Memory: 10MB

Kindly check

Thanks,
Jake

codebymikey’s picture

Thanks for looking into the issue.

Can the @todo comment be left in for future reference?

avpaderno’s picture

Issue summary: View changes

avpaderno changed the visibility of the branch 3349518-gitlab-ci-reports to hidden.

avpaderno’s picture

Status: Needs work » Needs review
codebymikey’s picture

Status: Needs review » Fixed

Thanks for all the work done on this guy!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.