mirror of
https://gitlab.com/soapbox-pub/shakespeare.git
synced 2026-12-06 00:27:24 +00:00
Fix stale template cache by re-cloning when force-pull fails
Shallow clones (depth=1) cause isomorphic-git's fetch to fail when the remote template has new commits. Instead of showing an error toast and falling back to the stale cached template, delete the cache and re-clone fresh to ensure users always get the latest template.
This commit is contained in:
3 files changed
+29
-37
No files matched your search
@@ -234,14 +234,6 @@ export default function Index() {
|
||||
prompt.trim(),
|
||||
template.url,
|
||||
projectId,
|
||||
() => {
|
||||
// Show a toast if template update fails (non-critical)
|
||||
toast({
|
||||
title: t('templateUpdateFailed'),
|
||||
description: t('templateUpdateFailedDescription'),
|
||||
variant: 'default',
|
||||
});
|
||||
},
|
||||
{ name: template.name, description: template.description }
|
||||
);
|
||||
|
||||
|
||||
Reference in new issue
Block a user