./lib/dolt/sinatra/multi_repo_browser.rb in dolt-0.21.0 vs ./lib/dolt/sinatra/multi_repo_browser.rb in dolt-0.22.0

- old
+ new

@@ -41,11 +41,11 @@ get "/*/tree/*:*" do begin repo, ref, path = params[:splat] tree(repo, ref, path) rescue Exception => err - error(err, repo, ref) + render_error(err, repo, ref) end end get "/*/tree/*" do force_ref(params[:splat], "tree", "master") @@ -54,11 +54,11 @@ get "/*/blob/*:*" do begin repo, ref, path = params[:splat] blob(repo, ref, path) rescue Exception => err - error(err, repo, ref) + render_error(err, repo, ref) end end get "/*/blob/*" do force_ref(params[:splat], "blob", "master") @@ -67,11 +67,11 @@ get "/*/raw/*:*" do begin repo, ref, path = params[:splat] raw(repo, ref, path) rescue Exception => err - error(err, repo, ref) + render_error(err, repo, ref) end end get "/*/raw/*" do force_ref(params[:splat], "raw", "master") @@ -80,11 +80,11 @@ get "/*/blame/*:*" do begin repo, ref, path = params[:splat] blame(repo, ref, path) rescue Exception => err - error(err, repo, ref) + render_error(err, repo, ref) end end get "/*/blame/*" do force_ref(params[:splat], "blame", "master") @@ -93,11 +93,11 @@ get "/*/history/*:*" do begin repo, ref, path = params[:splat] history(repo, ref, path, (params[:commit_count] || 20).to_i) rescue Exception => err - error(err, repo, ref) + render_error(err, repo, ref) end end get "/*/history/*" do force_ref(params[:splat], "history", "master") @@ -105,19 +105,19 @@ get "/*/refs" do begin refs(params[:splat].first) rescue Exception => err - error(err, repo, nil) + render_error(err, repo, nil) end end get "/*/tree_history/*:*" do begin repo, ref, path = params[:splat] tree_history(repo, ref, path) rescue Exception => err - error(err, repo, ref) + render_error(err, repo, ref) end end private def force_ref(args, action, ref)