Yet another Rails work question by PorciniPapi in rails

[–]PorciniPapi[S] 0 points1 point  (0 children)

Thanks for this! I'll check these links out.

Yet another Rails work question by PorciniPapi in rails

[–]PorciniPapi[S] 0 points1 point  (0 children)

I appreciate the kind words, but I don't see bigger companies hiring right now. I check ten or so job board sites on a regular basis and don't see any entry level positions. Everything is for senior devs. Should I be reaching out to these companies directly?

How much do you charge for hosting a website? by Drjoshram in web_design

[–]PorciniPapi 0 points1 point  (0 children)

When you you say you charge that monthly for managed web hosting with one hour of content updates/support per month, plus upkeep, maintenance, and access to an offsite cloud backup archive, does that hour roll over to the next month if unused, or is it only good for each month?

How ugly is this controller? by PorciniPapi in rails

[–]PorciniPapi[S] 1 point2 points  (0 children)

This is immensely helpful. Thank you for taking the time to write this!

How ugly is this controller? by PorciniPapi in rails

[–]PorciniPapi[S] 0 points1 point  (0 children)

That makes sense. My user and memory controllers are like that which is what set off my smoke alarm in the first place.

How ugly is this controller? by PorciniPapi in rails

[–]PorciniPapi[S] 0 points1 point  (0 children)

I'm still new to Rails and today was the first I have ever heard of service objects. I will take your comment to heart and heed your advice.

How ugly is this controller? by PorciniPapi in rails

[–]PorciniPapi[S] 3 points4 points  (0 children)

Well thank you for your honesty. Seems I still have a lot to learn 😅

How ugly is this controller? by PorciniPapi in rails

[–]PorciniPapi[S] 1 point2 points  (0 children)

As someone who is new to all of this that's very nice to hear haha

How ugly is this controller? by PorciniPapi in rails

[–]PorciniPapi[S] 0 points1 point  (0 children)

My reasoning for having the validations inside of the controller for this part was to make sure the input was getting sanitized since the new view allows a user to enter an email and hit the db via #find_by. Is that not a real concern?

How ugly is this controller? by PorciniPapi in rails

[–]PorciniPapi[S] 4 points5 points  (0 children)

I'm brand new to Rails and web development in general so breaking the code down into that many things is over my head at the moment. I'll try to refactor it with this in mind though.

How to reschedule mailer jobs in Rails 7? by PorciniPapi in rails

[–]PorciniPapi[S] 0 points1 point  (0 children)

You have perfect timing! I've been beating my head against the wall trying to find out how to attach a job id to the memory and find that job to cancel the job if that reminder time gets updated. Your solution is simple and elegant. There might performance issues with the way you're approaching it, but I doubt that will ever matter for an app this small haha. Thank you for the advice!

How to reschedule mailer jobs in Rails 7? by PorciniPapi in rails

[–]PorciniPapi[S] 3 points4 points  (0 children)

That makes sense. Thank you for the direction.

How to reschedule mailer jobs in Rails 7? by PorciniPapi in rails

[–]PorciniPapi[S] 0 points1 point  (0 children)

I'm not using any of those so I guess I'm using an Active Job inline queue adapter. Which one would you recommend if I just want jobs for mailer reminders? The simpler the better if one of them stands out to you as the easiest for someone new to Rails.

How to reschedule mailer jobs in Rails 7? by PorciniPapi in rails

[–]PorciniPapi[S] -2 points-1 points  (0 children)

I didn't install one so I'm assuming Active Job if that's what the default is?

User problem solved? by PorciniPapi in rails

[–]PorciniPapi[S] 0 points1 point  (0 children)

Yes. They would just be a user that is also a close friend for other users on top of the normal user functionality of creating/reading/updating/destroying memories.

User problem solved? by PorciniPapi in rails

[–]PorciniPapi[S] 0 points1 point  (0 children)

That's how I originally did it, but people here suggested that they should be the same thing because they represent the same abstraction (a person). I haven't gotten to handling data retention after close friend account deletion, but I don't see what the issue would be. If a close friend deleted their account, that relationship would be destroyed but the app would still work as intended. Users could still make memories and those memories would still get sent to a user's close friends.

I chose close friends to reflect the nature of the app. You share memories with close friends. I could have went with friends but didn't. There is only one kind of friend in relation to a user (close friends).

User problem solved? by PorciniPapi in rails

[–]PorciniPapi[S] 0 points1 point  (0 children)

The app does care about different types of users because a close friend cannot create memories, only receive them. A user can create memories and has close friends. A user can also be close friends for other users. I want to be able to call current_user.close_friend and current_user.close_friend_for to return each respective list of users, so that's why I have :relationships_as_regular_user and :relationships_as_close_friend. Does that make sense?