# Error 500 when editing the "closed topic" post

**URL:** <https://meta.discourse.org/t/error-500-when-editing-the-closed-topic-post/50124>\
**Category:** Product Support\
**Created:** [9월 14, 2016, 5:26오전 UTC](https://meta.discourse.org/t/error-500-when-editing-the-closed-topic-post/50124 "2016-09-14T05:26:10Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![barryvan](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/barryvan/32/82635_2.png) [@barryvan](https://meta.discourse.org/u/barryvan)\
**Post date:** [9월 14, 2016, 5:26오전 UTC](https://meta.discourse.org/t/error-500-when-editing-the-closed-topic-post/50124/1 "2016-09-14T05:26:10Z")

</div>

I just closed a topic, but meant to post a message explaining why before. I figured I’d edit the “closed topic” post to do so – but when I hit “save”, I received an error 500. It does seem to have persisted my changes, though.

Looking through the logs, I _think_ that the relevant entry is:

```plaintext
ActiveRecord::RecordNotUnique (PG::UniqueViolation: ERROR: duplicate key value violates unique constraint "unique_post_links"
DETAIL: Key (topic_id, post_id, url)=(60, 791, /c/17-q-a) already exists.
: INSERT INTO "topic_links" ("post_id", "user_id", "topic_id", "url", "domain", "internal", "created_at", "updated_at") VALUES (791, 1, 60, '/c/17-q-a', 'community.seqta.com.au', 't', '2016-09-14 05:25:43.149457', '2016-09-14 05:25:43.149457') RETURNING "id")
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/rack-mini-profiler-0.10.1/lib/patches/db/pg.rb:93:in `exec'

```

---

_[View the full topic](https://meta.discourse.org/t/error-500-when-editing-the-closed-topic-post/50124)._
