memos icon indicating copy to clipboard operation
memos copied to clipboard

The preview images before April are all displayed the same.(2023年4月之前的图片预览图展示全部一样)

Open Jonnyan404 opened this issue 2 years ago • 2 comments

Describe the bug

The preview images before April are all displayed the same

Steps to reproduce

You can view the pictures before April.

Screenshots or additional context

No response

Jonnyan404 avatar May 24 '23 13:05 Jonnyan404

Because the UUID was only added on April 3rd, the UUID values before this date are the same, resulting in the same preview image being parsed.

https://github.com/usememos/memos/commit/1cab30f32f737844090240434defdd834b01ea74

Jonnyan404 avatar May 24 '23 14:05 Jonnyan404

Execute the following SQL into your database or wait next release.

UPDATE
  resource
SET
  public_id = printf (
    '%s-%s-%s-%s-%s',
    lower(hex(randomblob(4))),
    lower(hex(randomblob(2))),
    lower(hex(randomblob(2))),
    lower(hex(randomblob(2))),
    lower(hex(randomblob(6)))
  );

boojack avatar May 26 '23 01:05 boojack