From 0974ef8bd47d3148beb7dfa16295f9b7f7f89808 Mon Sep 17 00:00:00 2001 From: evazion Date: Wed, 5 Apr 2017 00:37:05 -0500 Subject: [PATCH] iqdbs: raise exception if not configured. --- app/controllers/iqdb_queries_controller.rb | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/controllers/iqdb_queries_controller.rb b/app/controllers/iqdb_queries_controller.rb index 3b0a5e334..8f1393ed2 100644 --- a/app/controllers/iqdb_queries_controller.rb +++ b/app/controllers/iqdb_queries_controller.rb @@ -4,8 +4,7 @@ class IqdbQueriesController < ApplicationController def create if !Danbooru.config.iqdbs_server - render :nothing => true - return + raise NotImplementedError.new("the IQDBs service isn't configured. Similarity searches are not available.") end if params[:url] @@ -32,4 +31,4 @@ protected @results = @download.matches render :layout => false, :action => "create_by_post" end -end \ No newline at end of file +end