Fixes error initializing database
This commit is contained in:
@@ -4,11 +4,11 @@ module Measurable
|
|||||||
class_methods do
|
class_methods do
|
||||||
|
|
||||||
def title_max_length
|
def title_max_length
|
||||||
@@title_max_length ||= self.columns.find { |c| c.name == 'title' }.limit || 80
|
@@title_max_length ||= (self.columns.find { |c| c.name == 'title' }.limit rescue nil) || 80
|
||||||
end
|
end
|
||||||
|
|
||||||
def responsible_name_max_length
|
def responsible_name_max_length
|
||||||
@@responsible_name_max_length ||= self.columns.find { |c| c.name == 'responsible_name' }.limit || 60
|
@@responsible_name_max_length ||= (self.columns.find { |c| c.name == 'responsible_name' }.limit rescue nil) || 60
|
||||||
end
|
end
|
||||||
|
|
||||||
def question_max_length
|
def question_max_length
|
||||||
|
|||||||
Reference in New Issue
Block a user