1
0
Fork 0

Remove old inflections

This commit is contained in:
Alex Kotov 2023-03-25 02:17:31 +04:00
parent 813ed52c7c
commit 7ea631ca61
Signed by: kotovalexarian
GPG Key ID: 553C0EBBEB5D5F08
1 changed files with 1 additions and 6 deletions

View File

@ -32,7 +32,6 @@ get '/words/:id' do
part_of_speech: context.part_of_speech_name(word_id),
commentary: word_info[:commentary],
translations: context.translations(word_id),
inflections_old: word_info[:inflections],
inflections: context.inflections(word_id),
examples: context.examples(word_id),
})
@ -81,7 +80,7 @@ public
word_id = Integer word_id
row = @db_conn.exec_params(
'SELECT primary_form, commentary, inflections FROM words WHERE id = $1',
'SELECT primary_form, commentary FROM words WHERE id = $1',
[word_id],
).to_a.first
@ -91,13 +90,9 @@ public
commentary = String(row['commentary']).strip.freeze
commentary = nil if commentary.empty?
inflections = String(row['inflections']).strip.freeze
inflections = nil if inflections.empty?
{
primary_form: primary_form,
commentary: commentary,
inflections: inflections,
}.freeze
end