$ phpcs --standard=Drupalpractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml tagclouds/
Xdebug: [Step Debug] Time-out connecting to debugging client, waited: 200 ms. Tried: localhost:9000 (through xdebug.client_host/xdebug.client_port) :-(

FILE: C:\Users\SI-001\Downloads\tagclouds\src\CloudBuilder.php
-------------------------------------------------------------------------------------------------
106 | WARNING | Node::load calls should be avoided in classes, use dependency injection instead
130 | WARNING | Node::load calls should be avoided in classes, use dependency injection instead
-------------------------------------------------------------------------------------------------

Comments

Rakhi Soni created an issue. See original summary.

rakhi soni’s picture

Assigned: rakhi soni » Unassigned
Status: Active » Needs review
StatusFileSize
new2.64 KB

Kindly review patch,,

joseph.olstad’s picture

Status: Needs review » Needs work

╰❯ $ patch -p1 < node-load-calls-should-be-avoided-3302357-2.patch
patching file src/CloudBuilder.php
Hunk #1 FAILED at 4.
Hunk #2 FAILED at 28.
Hunk #3 FAILED at 103.
Hunk #4 FAILED at 127.
4 out of 4 hunks FAILED -- saving rejects to file src/CloudBuilder.php.rej

sourabhjain’s picture

Assigned: Unassigned » sourabhjain

I will work on this.

sourabhjain’s picture

Assigned: sourabhjain » Unassigned
Status: Needs work » Needs review
StatusFileSize
new2.04 KB

I have updated the patch.
Please review.

asad_ahmed’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: -phpcs

Patch #5 applied cleanly and working fine for me and solve the issue mentioned above.

joseph.olstad’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

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