]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 455301: Don't show password box on userprefs.cgi if your auth method didn't use...
authorDirk Steinmetz <rsjtdrjgfuzkfg@abwesend.de>
Wed, 25 Sep 2013 17:47:55 +0000 (19:47 +0200)
committerFrédéric Buclin <LpSolit@gmail.com>
Wed, 25 Sep 2013 17:47:55 +0000 (19:47 +0200)
r=LpSolit a=justdave

template/en/default/account/prefs/account.html.tmpl

index a00b5df97c8e24ab2f989d461ec86873c8b7585f..b6c1ce1f8957a7bb12512b7757c515c1e3fd4715 100644 (file)
   #%]
 
 <table>
-  <tr>
-    <td colspan="3">
-      Please enter your existing password to confirm account changes.
-    </td>
-  </tr>
-  <tr>
-    <th>Password:</th>
-    <td>
-      <input type="hidden" name="old_login" value="[% user.login FILTER html %]">
-      <input type="password" name="old_password">
-    </td>
-  </tr>              
-  <tr>
-    <td colspan="2"><hr></td>
-  </tr>
+  [% IF user.authorizer.can_change_password
+        || (user.authorizer.can_change_email && Param('allowemailchange')) %]
+    <tr>
+      <td colspan="3">
+        Please enter your existing password to confirm account changes.
+      </td>
+    </tr>
+    <tr>
+      <th>Password:</th>
+      <td>
+        <input type="hidden" name="old_login" value="[% user.login FILTER html %]">
+        <input type="password" name="old_password">
+      </td>
+    </tr>
+    <tr>
+      <td colspan="2"><hr></td>
+    </tr>
+  [% END %]
+
   [% IF user.authorizer.can_change_password %]
     <tr>
       <th>New password:</th>