mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-03 03:40:49 +08:00
fix: project private params to boolean
This commit is contained in:
@@ -60,6 +60,6 @@ class Projects::CreateService < ApplicationService
|
||||
# end
|
||||
|
||||
def repo_is_public
|
||||
params[:private].blank? ? true : !params[:private]
|
||||
params[:private].blank? ? true : !(ActiveModel::Type::Boolean.new.cast(params[:private]).nil? ? false : ActiveModel::Type::Boolean.new.cast(params[:private]))
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user