iqdbs: raise exception if not configured.
This commit is contained in:
@@ -4,8 +4,7 @@ class IqdbQueriesController < ApplicationController
|
|||||||
|
|
||||||
def create
|
def create
|
||||||
if !Danbooru.config.iqdbs_server
|
if !Danbooru.config.iqdbs_server
|
||||||
render :nothing => true
|
raise NotImplementedError.new("the IQDBs service isn't configured. Similarity searches are not available.")
|
||||||
return
|
|
||||||
end
|
end
|
||||||
|
|
||||||
if params[:url]
|
if params[:url]
|
||||||
@@ -32,4 +31,4 @@ protected
|
|||||||
@results = @download.matches
|
@results = @download.matches
|
||||||
render :layout => false, :action => "create_by_post"
|
render :layout => false, :action => "create_by_post"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user