Closed (fixed)
Project:
Lost & found issues
Component:
Twig templates
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
24 Oct 2012 at 17:50 UTC
Updated:
10 Nov 2012 at 20:30 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
vlad.dancerGood job!
Comment #2
steveoliver commentedMaybe this would be just a little cleaner?
Comment #3
steveoliver commentedThis is what my patch addresses:
We always set variables.
Use unique variable names here.
Unnecessarily long variables name.
Cleanup @see syntax.
Unnecessary check, know variables should always be defined.
Comment #4
EVIIILJ commented@steveoliver: Thank you for clarifying all your suggestions. They all make perfect sense, in fact I was battling them myself initially while creating the first patch but elected to go with similarities from the original theme_node_preview function. I like the alternative you suggested as well :)
Great to know, I will adopt this standard in future conversions I take on.
Attached is an updated patch including the suggested changes.
Comment #5
steveoliver commentedThanks, EVIIILJ. Committed in 2b55585.
Comment #6
decafdennis commentedSee http://drupal.org/node/156119