• 0 Posts
  • 14 Comments
Joined 2 years ago
cake
Cake day: October 13th, 2023

help-circle

  • Atlas_@lemmy.worldtoMemes@lemmy.mlPlausible deniability
    link
    fedilink
    arrow-up
    21
    arrow-down
    1
    ·
    6 months ago

    Ok, so imagine that you’re a billionaire and a really smart dude (as claimed by so many people on the internet). And you get into government and appear on TV and want to look good. You might hire a publicist, a PR team, some speechwriters, hell how about a body language consultant. When you go on TV you’re going to project exactly the image you intend to. Anything less would be careless and stupid, right?

    So yeah. This was a Nazi salute. And if you really want to argue that it wasn’t, that Musk doesn’t even know what a Nazi is, you gotta also accept that he’s grossly incompetent and should not be in government at all. Throw him out, we didn’t vote for him.


  • Play around with this for a bit: https://networthify.com/calculator/earlyretirement?income=50000&initialBalance=0&expenses=20000&annualPct=5&withdrawalRate=4

    Consider spending 30k yearly when you’re earning 50k. You can retire in about 20 years if you keep to that. You really gotta keep to it though, spending 40k means you’d have to work almost 40 years instead.

    Now compare that to spending 30k when making 100k. Now you can retire in 9 years. Even if you have to spend literally twice as much time+effort doing so, you end up with more of your life leftover.

    This is not to say that you should take a job you hate, but rather to say that making more money does make your life better, but only up to a point. If you find a job that you genuinely enjoy, great do that. If you’re picking between different things you dislike, translate it back into years instead of trying to understand it in made up funny money numbers. And when you get there, stop.






  • In addition to the excellent points made by steventhedev and koper:

    user.password = await hashPassword(user.password);

    Just this one line of code alone is wrong.

    1. It’s unclear, but quite likely that the type has changed here. Even in a duck typed language this is hard to manage and often leads to bugs.
    2. Even without a type change, you shouldn’t reuse an object member like this. Dramatically better to have password and hashed_password so that they never get mixed up. If you don’t want the raw password available after this point, zero it out or delete it.
    3. All of these style considerations apply 4x as strongly when it’s a piece of code that’s important to the security of your service, which obviously hashing passwords is.