Files
danbooru/app/views/users/deactivate.html.erb
evazion 3ffde5b23d users: move account deletion endpoint to /users/:id/deactivate.
Move the account deletion endpoint from /maintenance/users/deletion to either:

* https://danbooru.donmai.us/users/deactivate
* https://danbooru.donmai.us/users/:id/deactivate

This incidentally allows the Owner-level user to deactivate accounts belonging to other users. This
is meant for things like deactivating inactive accounts with invalid or abusive names. This is
limited to accounts below Gold level for security.
2022-11-05 19:09:56 -05:00

48 lines
1.7 KiB
Plaintext

<% page_title "Deactivate Account" %>
<%= render "secondary_links" %>
<div id="c-users">
<div id="a-deactivate">
<% if @user == CurrentUser.user %>
<h1>Deactivate Account</h1>
<% else %>
<h1>Deactivate Account: <%= link_to_user @user %></h1>
<% end %>
<div class="prose mb-4">
<p>
You can deactivate your <%= Danbooru.config.app_name %> account by entering your password below. Deactivating
your account will do the following things:
</p>
<ul>
<li>Change your username to a generic username (<i>user_<%= @user.id %></i>).</li>
<li>Delete your password, email address, and account settings.</li>
<li>Delete your favorites.</li>
<li>Delete your saved searches.</li>
</ul>
<p>
The following things will <strong>not</strong> be deleted:
</p>
<ul>
<li>Posts you've uploaded.</li>
<li>Your comments, forum posts, and private messages.</li>
<li>Your tag edits, wiki edits, translation notes, and any other contributions you've made to the site.</li>
<li>Your login history, including your IP address and geographic location. This is kept for moderation purposes.</li>
</ul>
<p>
Enter your password below to deactivate your account. This cannot be
undone. Your account cannot be recovered after it is deactivated.
</p>
</div>
<%= edit_form_for(:user, url: user_path(@user), method: :delete) do |f| %>
<%= f.input :password %>
<%= f.submit "Deactivate account", "data-confirm": "Are you sure you want to deactivate your account? This cannot be undone" %>
<% end %>
</div>
</div>