kopia lustrzana https://github.com/cheeaun/phanpy
Oops, forgot to put confirm dialog before boosting
rodzic
bf907abc17
commit
1538400dc0
|
@ -455,6 +455,14 @@ function Status({
|
||||||
count={reblogsCount}
|
count={reblogsCount}
|
||||||
onClick={async () => {
|
onClick={async () => {
|
||||||
try {
|
try {
|
||||||
|
if (!reblogged) {
|
||||||
|
const yes = confirm(
|
||||||
|
'Are you sure that you want to boost this post?',
|
||||||
|
);
|
||||||
|
if (!yes) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
// Optimistic
|
// Optimistic
|
||||||
states.statuses.set(id, {
|
states.statuses.set(id, {
|
||||||
...status,
|
...status,
|
||||||
|
|
Ładowanie…
Reference in New Issue