Commit Graph

9 Commits

Author SHA1 Message Date
Javi Martín
6af8ddd324 Extract component to render the date of birth
We reduce code duplication thanks to that, and make it easier
to change this field.

Note that there was one place where the "16.years" value was
hardcoded. We're moving the test for this case to the
component and changing it so the test doesn't use the default
age.

We're also removing the redundant helper method that had the
same code as a method in the User class which is called
everywhere else.
2024-11-12 15:15:34 +01:00
Javi Martín
66759d2dc0 Apply StringConcatenation rule in some places
This rule was added in Rubocop 0.89.0. However, there are some false
positives when we don't use interpolation but simply concatenate in
order to avoid long lines. Even if there weren't false positives, there
are places where we concatenate to emphasize the point that we're adding
a certain character to a text.

We might reconsider this rule in the future, since we generally prefer
interpolation over concatenation.
2020-10-23 12:01:39 +02:00
Javi Martín
db97f9d08c Add and apply rubocop rules for empty lines
We were very inconsistent regarding these rules.

Personally I prefer no empty lines around blocks, clases, etc... as
recommended by the Ruby style guide [1], and they're the default values
in rubocop, so those are the settings I'm applying.

The exception is the `private` access modifier, since we were leaving
empty lines around it most of the time. That's the default rubocop rule
as well. Personally I don't have a strong preference about this one.


[1] https://rubystyle.guide/#empty-lines-around-bodies
2019-10-24 17:11:47 +02:00
decabeza
21c6da3767 Use min age to participate setting on verification residence form 2019-03-22 16:15:48 +01:00
Julian Herrero
b460c024f3 Use double quotes in app/helpers 2019-03-15 09:26:49 +01:00
Bertocq
f6fe9cc7d2 Fix all Layout/SpaceAroundOperators rubocop issues and remove file list from rubocop_todo list 2017-06-26 18:04:20 +02:00
Bertocq
87e73e772c Remove all Lint/AmbiguousRegexpLiteral rubocop issues on code, and from rubocop_todo list 2017-06-19 10:45:18 +02:00
rgarcia
4bd0cbe777 adds mask to verified emails and phones 2015-08-30 15:14:23 +02:00
rgarcia
3ee68fd5d7 adds translations 2015-08-28 00:03:08 +02:00