Closed (fixed)
Project:
Drupal core
Version:
8.9.x-dev
Component:
block.module
Priority:
Minor
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
13 Jan 2020 at 06:35 UTC
Updated:
20 Feb 2020 at 20:29 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
hardik_patel_12 commentedKindly review a new patch
Comment #3
hardik_patel_12 commentedComment #4
longwaveExtra space after "as"
I realise this is unused but the code is easier to read with it in place.
Comment #5
hardik_patel_12 commentedKindly reveiw a new patch.
@longwave
, yes you are right but i thought it's good idea
to remove variable if it is not used.
Comment #6
hardik_patel_12 commentedComment #8
hardik_patel_12 commentedKindly review new patch , bymistakly added space near php tag.
Comment #9
hardik_patel_12 commentedComment #10
pandaski commentedLooks good here since $block2 never being used
Comment #11
catchPer other issues specifying the key helps with readability and people often do this intentionally even if the key isn't actually used. If we're going to make this a coding-style rule we should open a proper coding standards issue to do so.
Comment #12
Rangaswini commentedComment #13
pratik_kambleComment #14
pratik_kambleRerolled patch to keep the key in foreach.
Comment #15
pratik_kambleComment #16
longwave$id adds context here, I think it is more readable with it in place.
edit: I already said that in #4 :)
Comment #17
pratik_kamble@longwave updated the Patch to keep $id.
Comment #18
pratik_kambleComment #19
longwaveThanks, the one remaining one is fine.
Comment #21
catchCommitted 228df49 and pushed to 9.0.x. Thanks!