visit("/projects")
visit(post_comments_path(post))
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# app/models/application_record.rb | |
class ApplicationRecord < ActiveRecord::Base | |
self.abstract_class = true | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# app/policies/application_policy.rb | |
class ApplicationPolicy | |
attr_reader :user, :record | |
def initialize(current_user, record) | |
@user = user | |
@record = record | |
end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
04e449fd1e80b8e0d9c4048d3bf93adc ./saferun.sh | |
8b139ac5b93769623bd343318048238c ./legal/ICU License - ICU 1.8.1 and later.html | |
2100bdc885ac4cdc9783c562639ddc1f ./legal/OpenSSL.txt | |
10ec1bb9e39d6056d34cd954e09c6dc7 ./legal/LGPL v2.txt | |
c5232433d0f75d4f6c7974709fd898cb ./legal/licenses.txt | |
f094e5cb2db3826da69860d83db6a3b7 ./legal/libpng.txt | |
beb48b173a776d45fee6dd9b70cb6be7 ./legal/libtiff.txt | |
db1b7a668b2a6f47b2af88fb008ad555 ./legal/xiph.org.txt | |
844cfb3cf1a83eedc083c702c8a27f6c ./legal/libmspack.txt | |
85f70f1acc953dac84b1bd92acb992f3 ./legal/TomCrypt.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# frozen_string_literal: true | |
# Please include only the minimum code necessary to reproduce your issue. | |
require "bundler/inline" | |
# STEP ONE: What versions are you using? | |
gemfile(true) do | |
ruby "2.5.1" | |
source "https://rubygems.org" | |
gem "activerecord", "4.2.11" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# frozen_string_literal: true | |
# Please include only the minimum code necessary to reproduce your issue. | |
require "bundler/inline" | |
# STEP ONE: What versions are you using? | |
gemfile(true) do | |
ruby "2.5.1" | |
source "https://rubygems.org" | |
gem "activerecord", "4.2.11" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'bundler/inline' | |
gemfile(true) do | |
ruby '~> 2.5' | |
source 'https://rubygems.org' | |
gem 'benchmark-ips' | |
end | |
require 'benchmark/ips' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class UpdateForeignKey < ActiveRecord::Migration[5.0] | |
def change | |
add_reference :posts, :users, index: true, foreign_key: { on_delete: :cascade } | |
end | |
end |