Commit Graph

14 Commits

Author SHA1 Message Date
Georg Gadinger fb07eda972 remove errors 2022-12-29 20:57:28 +01:00
Georg Gadinger 9413d23a02 let Zeitwerk autoload the `lib/` directory
this also allows the UseCase classes to be hot reloaded in dev 🎉

- remove use_case requires (except for the exporter as Zeitwerk
  doesn't know about the subclasses)
- move version.rb to lib/retrospring so that Zeitwerk knows where
  to find Retrospring::Version
2022-12-29 20:57:28 +01:00
Andreas Nedbal 34de119bb1 Add translations for block/relationship ajax controllers 2022-07-06 21:54:34 +02:00
Karina Kwiatek 14dfef6a52 Add status messages for blocking/unblocking users 2022-06-13 11:56:34 +02:00
Karina Kwiatek d67ae1eb19 Only accept users to relationship use cases
Dry Types was having issues with taking either an object or string so it's easier to deal with just passing in an object directly
2022-06-13 11:56:34 +02:00
Karina Kwiatek 3b1287c424 Apply suggestions from @nilsding
Co-authored-by: Georg Gadinger <nilsding@nilsding.org>
2022-01-23 16:48:53 +01:00
Karina Kwiatek 731ee4bf69 Address review comments from @nilsding 2022-01-23 16:48:53 +01:00
Karina Kwiatek 677ce26e6c Use generic handling of our own exceptions
Noticed that we shouldn't be trying to catch specific exceptions as `Dry::Types` will throw its own exceptions for validation errors.
2022-01-23 16:48:53 +01:00
Karina Kwiatek 29d46b43db Fix lint error; use fail message for relationship create failures 2022-01-23 16:48:53 +01:00
Karina Kwiatek 8d59ef9398 Use `screen_name` instead of `target_user` param in `Ajax::RelationshipController` 2022-01-23 16:48:53 +01:00
Karina Kwiatek b4e0699e82 Fix lint errors 2022-01-23 16:48:53 +01:00
Karina Kwiatek 0ab822c33a Use full translation key for messages 2022-01-23 16:48:53 +01:00
Karina Kwiatek d609435f7c Update `Ajax::RelationshipController` to use usernames; Test Use Case 2022-01-23 16:48:53 +01:00
Karina Kwiatek 3962671135 Implement relationship logic as use case 2022-01-23 16:48:53 +01:00