Skip to content

Commit 2e4ff1f

Browse files
committed
Keep extra saved versions for Tiddlyspot sites
The idea is Tiddlyspot sites are legacy and deprecated, so I'm intentionally not adding all the features of Tiddlyhost sites, but there are some folks still using them. If they manage to break their site somehow, having previous versions available helps me help them to get it back to a working version. There'll be some impact on the storage I guess, but I'm not too worried about that.
1 parent e1b702e commit 2e4ff1f

2 files changed

Lines changed: 5 additions & 2 deletions

File tree

rails/app/models/tspot_site.rb

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,8 +152,10 @@ def redirect_tspot_to_url_enabled?
152152
Settings.feature_enabled?(:redirect_tspot_to_url, user)
153153
end
154154

155-
# No site history for tspot sites
155+
# For legacy Tiddlyspot sites we don't provide the site history
156+
# feature, but let's one keep some previous versions so we can
157+
# help users recover from a broken save.
156158
def keep_count
157-
1
159+
Settings.keep_counts[:tiddlyspot]
158160
end
159161
end

rails/config/settings.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ defaults:
5050
keep_counts:
5151
:free: 4
5252
:standard: 100
53+
:tiddlyspot: 4
5354

5455
development:
5556
url_defaults:

0 commit comments

Comments
 (0)