You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: ruby/ql/src/queries/performance/CouldBeHoisted.qhelp
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -15,7 +15,7 @@ Performance can usually be improved by performing a single database query outsid
15
15
</p>
16
16
</recommendation>
17
17
<example>
18
-
<p>The following (suboptimal) example code queries the User object in each iteration of the loop:</p>
18
+
<p>The following (suboptimal) example code queries the <code>User</code> object in each iteration of the loop:</p>
19
19
<samplesrc="examples/straight_loop.rb" />
20
20
<p>To improve the performance, we instead query the <code>User</code> object once outside the loop, gathering all necessary information in a single query:</p>
0 commit comments