 <p>Syntex error in closing of if block syntex.</p> <pre><code>1 &lt;% if current_user.admin? &amp;&amp; !current_user?(user) %&gt; 2 &lt;li&gt;&lt;%= link_to "Admin", users_path %&gt;&lt;/li&gt; 3 &lt;/end&gt; </code></pre> <p>Error at line 3, replace line 3 ie <code>&lt;/end&gt; with &lt;% end %&gt;</code></p>