Skip to content

Commit

Permalink
correct @todo format
Browse files Browse the repository at this point in the history
  • Loading branch information
mrysav committed Jun 19, 2020
1 parent edc0cb3 commit bffd4d3
Show file tree
Hide file tree
Showing 9 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ gem 'chronic'
gem 'pg_search'

# Settings
# @TODO: migrate to different settings gem
# @todo migrate to different settings gem
gem 'rails-settings-cached', '~> 0'
gem 'rails-settings-ui'

Expand Down
2 changes: 1 addition & 1 deletion app/assets/javascripts/administrate/custom_chrono.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ window.CustomizedChrono = (function() {
text: match[0],
index: match.index,
start: {
day: 1, // TODO: Not great
day: 1, // @todo Not great
month: 1,
year: parseInt(match[0], 10)
}
Expand Down
2 changes: 1 addition & 1 deletion app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
class ApplicationController < ActionController::Base
include Pagy::Backend
include Pundit
# @TODO: disable this if necessary
# @todo disable this if necessary
after_action :verify_authorized, unless: :devise_controller?

helper MarkdownHelper
Expand Down
2 changes: 1 addition & 1 deletion app/jobs/create_snapshot_job.rb
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ def add_citations(zio)
# Decomposes a rich_text field by saving the text as well
# as the associated attachments.
#
# @TODO: Possible bug!
# @todo Possible bug!
#
# If two attachments are different files, but have the same filename,
# this could result in overwriting one of them.
Expand Down
6 changes: 3 additions & 3 deletions app/jobs/restore_snapshot_job.rb
Original file line number Diff line number Diff line change
Expand Up @@ -75,12 +75,12 @@ def handle_photo(filename, io)
photo_filename = fn_cap.captures[1]
photo = Photo.find(photo_id)
orig_updated_at = photo.updated_at
# @TODO: patch this so the photo doesn't have to be read into memory
# @todo patch this so the photo doesn't have to be read into memory
photo.image.attach(io: StringIO.new(io.read), filename: photo_filename)
photo.update_columns(updated_at: orig_updated_at)
end

# @TODO: This needs to handle attachments too
# @todo This needs to handle attachments too
# This is broken for now
def handle_note(filename, io, notes_buffer)
content_match = filename.match(%r{\ANotes\/note_([0-9]+)\.html\z})
Expand All @@ -99,7 +99,7 @@ def handle_note(filename, io, notes_buffer)

fname = filename.gsub!(%r{^Notes\/note_[0-9]+/}, '')

# @TODO: Possible bug!
# @todo Possible bug!
# See the create_snapshot_job for the duplicate file/filename problem
inner_html.css("action-text-attachment[filename='#{fname}']")
.each do |attachment|
Expand Down
2 changes: 1 addition & 1 deletion app/models/concerns/parseable_date.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def parse(date)
parsed_date
end

# @TODO: In the event I need to parse years < 1000 or > 9999... fix this
# @todo In the event I need to parse years < 1000 or > 9999... fix this
def self.parse_four_digit_year(date)
Date.new(date.to_i) if !date.nil? && date.match(/^[1-9][0-9]{3}$/)
end
Expand Down
2 changes: 1 addition & 1 deletion app/models/person.rb
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ def probably_dead?

private

# @TODO: More sophisticated probably_alive logic
# @todo More sophisticated probably_alive logic
# Obviously a person can live to be older than 90,
# but the US census releases records after 70 years
# so I figure I'm good here
Expand Down
2 changes: 1 addition & 1 deletion app/views/citations/_citation.html.erb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<%
# @TODO: Make a better partial for Citations
# @todo Make a better partial for Citations
%>
<%= citation.text %>
2 changes: 1 addition & 1 deletion spec/jobs/restore_snapshot_job_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
reference_snapshot[:hashes].keys.each do |file|
ref_hash = reference_snapshot[:hashes][file]
new_hash = new_snapshot[:hashes][file]
# @TODO: there needs to be better equality checking for snapshots.
# @todo there needs to be better equality checking for snapshots.
# When restored, apparently sometimes things get out of order even
# though the data *inside* each record is fine.
if file.ends_with?('.json') && new_hash != ref_hash
Expand Down

0 comments on commit bffd4d3

Please sign in to comment.