When you edit a post it recalculates the bells as if it were a new post.
Say you make a post and gain 5 bells. You then decide to edit your post. When you edit your post you will lose all the bells from the post, but once you hit "save" you'll gain the amount for your new post. So if you made your post shorter you'll get less bells, so you'll lose them, but if you made it longer you'll actually gain bells.
TL;DR - it's a recalculation. And you'll lose/gain bells depending on whether you shorten/lengthen your original post.