Skip to content

Commit

Permalink
Merge pull request fastladder#219 from onk/upgrade_to_rails_4_2_9
Browse files Browse the repository at this point in the history
Trivial upgrade to Rails v4.2.9
  • Loading branch information
onk committed Jul 26, 2017
2 parents 9dd1a6e + 0bbe995 commit ff1875d
Show file tree
Hide file tree
Showing 14 changed files with 79 additions and 50 deletions.
2 changes: 1 addition & 1 deletion Rakefile
Expand Up @@ -3,7 +3,7 @@

require File.expand_path('../config/application', __FILE__)

Fastladder::Application.load_tasks
Rails.application.load_tasks

desc 'Setup files for development'
task 'setup' do
Expand Down
4 changes: 2 additions & 2 deletions app/assets/javascripts/application.js
Expand Up @@ -2,12 +2,12 @@
// listed below.
//
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.
// or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
//
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// compiled file.
//
// Read Sprockets README (https://github.com/sstephenson/sprockets#sprockets-directives) for details
// Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
// about supported directives.
//
//= require_tree ./vendor
Expand Down
8 changes: 5 additions & 3 deletions app/assets/stylesheets/application.css
Expand Up @@ -3,10 +3,12 @@
* listed below.
*
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
* or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.
* or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
*
* You're free to add application-wide styles to this file and they'll appear at the top of the
* compiled file, but it's generally better to create a new file per style scope.
* You're free to add application-wide styles to this file and they'll appear at the bottom of the
* compiled file so the styles you add here take precedence over styles defined in any styles
* defined in the other CSS/SCSS files in this directory. It is generally better to create a new
* file per style scope.
*
*= require_self
*= require common
Expand Down
1 change: 0 additions & 1 deletion app/helpers/application_helper.rb
@@ -1,4 +1,3 @@
# Methods added to this helper will be available to all templates in the application.
module ApplicationHelper
def disp_users(num)
"#{num} #{(num > 1 ? "users" : "user")}"
Expand Down
5 changes: 0 additions & 5 deletions config/application.rb
Expand Up @@ -23,11 +23,6 @@ class Application < Rails::Application
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
# config.i18n.default_locale = :de

# i18n-js 2.1.2 raise error
# > Cannot precompile i18n-js translations unless environment is initialized.
# > Please set config.assets.initialize_on_precompile to true.
config.assets.initialize_on_precompile = true

# Do not swallow errors in after_commit/after_rollback callbacks.
config.active_record.raise_in_transactional_callbacks = true
end
Expand Down
2 changes: 1 addition & 1 deletion config/initializers/cookies_serializer.rb
@@ -1,3 +1,3 @@
# Be sure to restart your server when you modify this file.

Rails.application.config.action_dispatch.cookies_serializer = :hybrid
Rails.application.config.action_dispatch.cookies_serializer = :json
10 changes: 10 additions & 0 deletions config/initializers/to_time_preserves_timezone.rb
@@ -0,0 +1,10 @@
# Be sure to restart your server when you modify this file.

# Preserve the timezone of the receiver when calling to `to_time`.
# Ruby 2.4 will change the behavior of `to_time` to preserve the timezone
# when converting to an instance of `Time` instead of the previous behavior
# of converting to the local system timezone.
#
# Rails 5.0 introduced this config option so that apps made with earlier
# versions of Rails are not affected when upgrading.
ActiveSupport.to_time_preserves_timezone = true
2 changes: 0 additions & 2 deletions doc/README_FOR_APP

This file was deleted.

31 changes: 20 additions & 11 deletions public/404.html
Expand Up @@ -2,17 +2,23 @@
<html>
<head>
<title>The page you were looking for doesn't exist (404)</title>
<meta name="viewport" content="width=device-width,initial-scale=1">
<style>
body {
background-color: #EFEFEF;
color: #2E2F30;
text-align: center;
font-family: arial, sans-serif;
margin: 0;
}

div.dialog {
width: 25em;
margin: 4em auto 0 auto;
width: 95%;
max-width: 33em;
margin: 4em auto 0;
}

div.dialog > div {
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
Expand All @@ -21,7 +27,8 @@
border-top-left-radius: 9px;
border-top-right-radius: 9px;
background-color: white;
padding: 7px 4em 0 4em;
padding: 7px 12% 0;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}

h1 {
Expand All @@ -30,29 +37,31 @@
line-height: 1.5em;
}

body > p {
width: 33em;
margin: 0 auto 1em;
padding: 1em 0;
div.dialog > p {
margin: 0 0 1em;
padding: 1em;
background-color: #F7F7F7;
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #999;
border-bottom-left-radius: 4px;
border-bottom-right-radius: 4px;
border-top-color: #DADADA;
color: #666;
box-shadow:0 3px 8px rgba(50, 50, 50, 0.17);
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
</style>
</head>

<body>
<!-- This file lives in public/404.html -->
<div class="dialog">
<h1>The page you were looking for doesn't exist.</h1>
<p>You may have mistyped the address or the page may have moved.</p>
<div>
<h1>The page you were looking for doesn't exist.</h1>
<p>You may have mistyped the address or the page may have moved.</p>
</div>
<p>If you are the application owner check the logs for more information.</p>
</div>
<p>If you are the application owner check the logs for more information.</p>
</body>
</html>
31 changes: 20 additions & 11 deletions public/422.html
Expand Up @@ -2,17 +2,23 @@
<html>
<head>
<title>The change you wanted was rejected (422)</title>
<meta name="viewport" content="width=device-width,initial-scale=1">
<style>
body {
background-color: #EFEFEF;
color: #2E2F30;
text-align: center;
font-family: arial, sans-serif;
margin: 0;
}

div.dialog {
width: 25em;
margin: 4em auto 0 auto;
width: 95%;
max-width: 33em;
margin: 4em auto 0;
}

div.dialog > div {
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
Expand All @@ -21,7 +27,8 @@
border-top-left-radius: 9px;
border-top-right-radius: 9px;
background-color: white;
padding: 7px 4em 0 4em;
padding: 7px 12% 0;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}

h1 {
Expand All @@ -30,29 +37,31 @@
line-height: 1.5em;
}

body > p {
width: 33em;
margin: 0 auto 1em;
padding: 1em 0;
div.dialog > p {
margin: 0 0 1em;
padding: 1em;
background-color: #F7F7F7;
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #999;
border-bottom-left-radius: 4px;
border-bottom-right-radius: 4px;
border-top-color: #DADADA;
color: #666;
box-shadow:0 3px 8px rgba(50, 50, 50, 0.17);
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
</style>
</head>

<body>
<!-- This file lives in public/422.html -->
<div class="dialog">
<h1>The change you wanted was rejected.</h1>
<p>Maybe you tried to change something you didn't have access to.</p>
<div>
<h1>The change you wanted was rejected.</h1>
<p>Maybe you tried to change something you didn't have access to.</p>
</div>
<p>If you are the application owner check the logs for more information.</p>
</div>
<p>If you are the application owner check the logs for more information.</p>
</body>
</html>
29 changes: 19 additions & 10 deletions public/500.html
Expand Up @@ -2,17 +2,23 @@
<html>
<head>
<title>We're sorry, but something went wrong (500)</title>
<meta name="viewport" content="width=device-width,initial-scale=1">
<style>
body {
background-color: #EFEFEF;
color: #2E2F30;
text-align: center;
font-family: arial, sans-serif;
margin: 0;
}

div.dialog {
width: 25em;
margin: 4em auto 0 auto;
width: 95%;
max-width: 33em;
margin: 4em auto 0;
}

div.dialog > div {
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
Expand All @@ -21,7 +27,8 @@
border-top-left-radius: 9px;
border-top-right-radius: 9px;
background-color: white;
padding: 7px 4em 0 4em;
padding: 7px 12% 0;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}

h1 {
Expand All @@ -30,28 +37,30 @@
line-height: 1.5em;
}

body > p {
width: 33em;
margin: 0 auto 1em;
padding: 1em 0;
div.dialog > p {
margin: 0 0 1em;
padding: 1em;
background-color: #F7F7F7;
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #999;
border-bottom-left-radius: 4px;
border-bottom-right-radius: 4px;
border-top-color: #DADADA;
color: #666;
box-shadow:0 3px 8px rgba(50, 50, 50, 0.17);
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
</style>
</head>

<body>
<!-- This file lives in public/500.html -->
<div class="dialog">
<h1>We're sorry, but something went wrong.</h1>
<div>
<h1>We're sorry, but something went wrong.</h1>
</div>
<p>If you are the application owner check the logs for more information.</p>
</div>
<p>If you are the application owner check the logs for more information.</p>
</body>
</html>
2 changes: 0 additions & 2 deletions public/javascripts/application.js

This file was deleted.

2 changes: 1 addition & 1 deletion public/robots.txt
@@ -1,4 +1,4 @@
# See http://www.robotstxt.org/wc/norobots.html for documentation on how to use the robots.txt file
# See http://www.robotstxt.org/robotstxt.html for documentation on how to use the robots.txt file
#
# To ban all spiders from the entire site uncomment the next two lines:
# User-agent: *
Expand Down
Empty file removed vendor/plugins/.keep
Empty file.

0 comments on commit ff1875d

Please sign in to comment.