Skip to content

Commit 11136b9

Browse files
committed
Revert "Start free Basil month"
This reverts commit b0a2e1e.
1 parent 50035d6 commit 11136b9

File tree

7 files changed

+1374
-135
lines changed

7 files changed

+1374
-135
lines changed

app/controllers/basil_controller.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ def content
207207
@in_progress_commissions = @commissions.select { |c| c.completed_at.nil? }
208208
@generated_images_count = current_user.basil_commissions.with_deleted.count
209209

210-
@can_request_another = (true || current_user.on_premium_plan?) || @generated_images_count < BasilService::FREE_IMAGE_LIMIT
210+
@can_request_another = current_user.on_premium_plan? || @generated_images_count < BasilService::FREE_IMAGE_LIMIT
211211
@can_request_another = @can_request_another && @in_progress_commissions.count < BasilService::MAX_JOB_QUEUE_SIZE
212212
end
213213

@@ -454,7 +454,7 @@ def review
454454

455455
def commission
456456
@generated_images_count = current_user.basil_commissions.with_deleted.count
457-
if false && !current_user.on_premium_plan? && @generated_images_count > BasilService::FREE_IMAGE_LIMIT
457+
if !current_user.on_premium_plan? && @generated_images_count > BasilService::FREE_IMAGE_LIMIT
458458
redirect_back fallback_location: basil_path, notice: "You've reached your free image limit. Please upgrade to generate more images."
459459
return
460460
end

app/controllers/browse_controller.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,7 @@ def tag
158158
# Set a default accent color for the page
159159
@accent_color = 'purple'
160160

161+
161162
# Sort content types so Characters always appear first
162163
@tagged_content = @tagged_content.sort_by do |content_group|
163164
if content_group[:type] == 'Character'

app/controllers/content_controller.rb

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# TODO: we should probably spin off an Api::ContentController for #api_sort and anything else
44
# api-wise we need
55
class ContentController < ApplicationController
6-
before_action :authenticate_user!, except: [:show, :changelog, :api_sort] \
6+
before_action :authenticate_user!, except: [:show, :changelog, :api_sort, :gallery] \
77
+ Rails.application.config.content_types[:all_non_universe].map { |type| type.name.downcase.pluralize.to_sym }
88

99
skip_before_action :cache_most_used_page_information, only: [
@@ -430,6 +430,7 @@ def gallery
430430
# Get all images for this content with proper ordering
431431
# Only show private images to the owner or contributors
432432
is_owner_or_contributor = false
433+
# Check if the user is the owner or a contributor
433434
if current_user.present? && (@content.user == current_user ||
434435
(@content.respond_to?(:universe_id) &&
435436
@content.universe_id.present? &&
@@ -854,6 +855,21 @@ def set_navbar_actions
854855
@navbar_actions = []
855856

856857
return if [AttributeCategory, AttributeField].include?(content_type)
858+
859+
# Set up navbar actions for gallery specifically
860+
if action_name == 'gallery' && @content.present?
861+
# Add a link to view the content page
862+
@navbar_actions << {
863+
label: @content.name,
864+
href: polymorphic_path(@content)
865+
}
866+
867+
# Add a gallery title indicator
868+
@navbar_actions << {
869+
label: 'Gallery',
870+
href: send("gallery_#{@content.class.name.downcase}_path", @content)
871+
}
872+
end
857873
end
858874

859875
def set_sidenav_expansion

app/views/basil/content.html.erb

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -95,10 +95,6 @@ function commission_basil(style) {
9595
-->
9696
</div>
9797

98-
<div style="margin-top: 1.5rem; margin-bottom: 1rem;" class="card-panel yellow lighten-5 black-text">
99-
Image generation is a Premium feature, but this month (June 2025), all users can generate unlimited images for free!
100-
</div>
101-
<!--
10298
<div style="margin-top: 1.5rem; margin-bottom: 1rem;">
10399
<% unless current_user.on_premium_plan? %>
104100
<div class="orange lighten-2 card-panel">
@@ -119,7 +115,6 @@ function commission_basil(style) {
119115
</div>
120116
<% end %>
121117
</div>
122-
-->
123118
</div>
124119
<% end %>
125120

app/views/basil/index.html.erb

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,6 @@
3939
</div>
4040
<div class="col s12 m8 l9">
4141

42-
<div style="margin-top: 1.5rem; margin-bottom: 1rem;" class="card-panel yellow lighten-5">
43-
Image generation is a Premium feature, but this month (June 2025), all users can generate unlimited images for free!
44-
</div>
45-
<!--
4642
<% unless current_user.on_premium_plan? %>
4743
<div class="orange lighten-2 card-panel">
4844
<strong>
@@ -61,7 +57,6 @@
6157
<% end %>
6258
</div>
6359
<% end %>
64-
-->
6560

6661
<% if @universe_scope %>
6762
<div class="card-panel <%= Universe.color %> white-text">

0 commit comments

Comments
 (0)