Fixed post updating

This commit is contained in:
rawleyIfowler
2022-03-13 09:46:56 -05:00
parent 2b62838435
commit 736d885f6e
2 changed files with 2 additions and 2 deletions

View File

@@ -22,7 +22,7 @@ import (
type BlogPost struct {
gorm.Model
Url string `json:"url" gorm:"primaryKey"`
Url string `json:"url" gorm:"primaryKey unique"`
Title string `json:"title" gorm:"unique"`
Date string `json:"date" gorm:"default:NOW()"`
Content string `json:"content"`