mirror of
https://github.com/SrIzan10/hc-harbor.git
synced 2026-05-01 10:45:21 +00:00
whitelist create and deleted at
This commit is contained in:
@@ -257,6 +257,11 @@ module Api
|
||||
return render json: { error: "no perms lmaooo" }, status: :forbidden
|
||||
end
|
||||
|
||||
cool = %w[created_at deleted_at]
|
||||
if query.upcase.match?(/\b(#{not_cool.join('|')})\b/) && !query.upcase.match?(/\b(#{cool.join('|')})\b/)
|
||||
return render json: { error: "no perms lmaooo" }, status: :forbidden
|
||||
end
|
||||
|
||||
begin
|
||||
limited_query = query.strip
|
||||
unless limited_query.upcase.include?("LIMIT")
|
||||
|
||||
Reference in New Issue
Block a user