changeset 246:8ab17063419f

Forgot to push production's updates.
author edogawaconan <me@myconan.net>
date Mon, 07 Oct 2013 04:18:17 +0000
parents 8dfbf854fad3 (current diff) e413246bb589 (diff)
children 9aa67da381b0
files Gemfile Gemfile.lock
diffstat 4 files changed, 26 insertions(+), 29 deletions(-) [+]
line wrap: on
line diff
--- a/Gemfile	Fri Aug 09 08:43:08 2013 +0000
+++ b/Gemfile	Mon Oct 07 04:18:17 2013 +0000
@@ -14,7 +14,7 @@
 gem 'sass-rails', '~> 4.0.0.rc1'
 
 gem 'uglifier'
-gem 'anjlab-bootstrap-rails', require: 'bootstrap-rails'
+gem 'anjlab-bootstrap-rails', '~>2.3.0', require: 'bootstrap-rails'
 
 gem 'therubyrhino', platforms: :jruby
 
--- a/Gemfile.lock	Fri Aug 09 08:43:08 2013 +0000
+++ b/Gemfile.lock	Mon Oct 07 04:18:17 2013 +0000
@@ -21,10 +21,11 @@
       activesupport (= 4.0.0)
       arel (~> 4.0.0)
     activerecord-deprecated_finders (1.0.3)
-    activerecord-jdbc-adapter (1.2.9.1)
-    activerecord-jdbcmysql-adapter (1.2.9)
-      activerecord-jdbc-adapter (~> 1.2.9)
-      jdbc-mysql (~> 5.1.0)
+    activerecord-jdbc-adapter (1.3.1)
+      activerecord (>= 2.2)
+    activerecord-jdbcmysql-adapter (1.3.1)
+      activerecord-jdbc-adapter (~> 1.3.1)
+      jdbc-mysql (>= 5.1.22)
     activesupport (4.0.0)
       i18n (~> 0.6, >= 0.6.4)
       minitest (~> 4.2)
@@ -35,34 +36,33 @@
       railties (>= 3.0)
       sass (>= 3.2)
     arel (4.0.0)
-    atomic (1.1.12)
-    atomic (1.1.12-java)
+    atomic (1.1.14)
+    atomic (1.1.14-java)
     bouncy-castle-java (1.5.0147)
     builder (3.1.4)
     erubis (2.7.0)
-    execjs (1.4.0)
-      multi_json (~> 1.0)
+    execjs (2.0.2)
     hike (1.2.3)
-    i18n (0.6.4)
+    i18n (0.6.5)
     jdbc-mysql (5.1.25)
     jquery-rails (3.0.4)
       railties (>= 3.0, < 5.0)
       thor (>= 0.14, < 2.0)
-    jruby-openssl (0.8.8)
+    jruby-openssl (0.9.2)
       bouncy-castle-java (>= 1.5.0147)
-    kgio (2.8.0)
+    kgio (2.8.1)
     mail (2.5.4)
       mime-types (~> 1.16)
       treetop (~> 1.4.8)
-    mime-types (1.23)
+    mime-types (1.25)
     minitest (4.7.5)
-    multi_json (1.7.8)
+    multi_json (1.8.1)
     mysql2 (0.3.13)
-    newrelic_rpm (3.6.6.147)
+    newrelic_rpm (3.6.7.159)
     polyglot (0.3.3)
-    puma (2.5.0)
+    puma (2.6.0)
       rack (>= 1.1, < 2.0)
-    puma (2.5.0-java)
+    puma (2.6.0-java)
       rack (>= 1.1, < 2.0)
     quiet_assets (1.0.2)
       railties (>= 3.1, < 5.0)
@@ -82,9 +82,9 @@
       activesupport (= 4.0.0)
       rake (>= 0.8.7)
       thor (>= 0.18.1, < 2.0)
-    raindrops (0.11.0)
+    raindrops (0.12.0)
     rake (10.1.0)
-    sass (3.2.10)
+    sass (3.2.12)
     sass-rails (4.0.0)
       railties (>= 4.0.0.beta, < 5.0)
       sass (>= 3.1.10)
@@ -102,16 +102,16 @@
       therubyrhino_jar (>= 1.7.3)
     therubyrhino_jar (1.7.4)
     thor (0.18.1)
-    thread_safe (0.1.2)
+    thread_safe (0.1.3)
       atomic
-    thread_safe (0.1.2-java)
+    thread_safe (0.1.3-java)
       atomic
     tilt (1.4.1)
-    treetop (1.4.14)
+    treetop (1.4.15)
       polyglot
       polyglot (>= 0.3.1)
     tzinfo (0.3.37)
-    uglifier (2.1.2)
+    uglifier (2.2.1)
       execjs (>= 0.3.0)
       multi_json (~> 1.0, >= 1.0.2)
     unicorn (4.6.3)
@@ -126,7 +126,7 @@
 DEPENDENCIES
   actionpack-page_caching
   activerecord-jdbcmysql-adapter
-  anjlab-bootstrap-rails
+  anjlab-bootstrap-rails (~> 2.3.0)
   jquery-rails
   jruby-openssl
   mysql2
--- a/app/controllers/pastes_controller.rb	Fri Aug 09 08:43:08 2013 +0000
+++ b/app/controllers/pastes_controller.rb	Mon Oct 07 04:18:17 2013 +0000
@@ -18,10 +18,7 @@
   def new
     @paste = Paste.new
     @paste.set_paste_key
-    begin
-      @paste.paste = Paste.find(params[:base]).paste
-    rescue
-    end
+    @paste.paste = Paste.safe_find(params[:base]).try(:paste)
 
     respond_to do |format|
       format.html # new.html.erb
--- a/app/views/pastes/show.html.erb	Fri Aug 09 08:43:08 2013 +0000
+++ b/app/views/pastes/show.html.erb	Mon Oct 07 04:18:17 2013 +0000
@@ -53,7 +53,7 @@
 <div>
   <ul class="nav nav-pills">
     <li><%= link_to 'Raw', paste_path(@paste, :txt) %></li>
-    <li><%= link_to 'New paste based on this', root_path(:base => @paste.id) %></li>
+    <li><%= link_to 'New paste based on this', root_path(:base => @paste.to_param) %></li>
     <li><%= link_to 'More Paste', root_path %></li>
   </ul>
 </div>