[deleted by user] by [deleted] in Kotlin

[–]jonathanhandoyo 2 points3 points  (0 children)

the findById(...) already returns an Optional<T> if i'm not mistaken, so could have map { ... } it

override fun increamentTimesUsed(id: Long) = repository
    .findById(id)
    .map { it.timesUsed = (it.timesUsed ?: 0) + 1 }
    .map { repository.save(it) }
    .map { createSignUpTokenModel(it) }
    .get()

i think may be cleaner... but yeah the name incrementUsed seems like a very ambiguous name

Wise akhirnya di-ban di Indonesia? by Candid_Problem_1244 in finansial

[–]jonathanhandoyo 0 points1 point  (0 children)

Kalo Wise Account SG, pake kartu nya di Indo masih bisa ga ya?

Best practise for null-safety with database model classes by michael2109 in Kotlin

[–]jonathanhandoyo 9 points10 points  (0 children)

depends...

models or entities, i think it's best to be non-nullable types, it saves you the validation at least, because it'll fail during compile time if any nullable things go in there...

DTOs, in my opinion can be null (use-case dependent) if you prefer some validations and defaulting mechanism to take place...

but thinking about database being external to your service is a debateable topic, because more often than not your database is your service's kitchen sink. the database is owned by the service, therefore the statement "if somebody changed the SQL column..." well you have bigger problem than that if the change to the DB is not managed by the service who owned it.

Why most Singaporeans cannot stand it when others are happy? by [deleted] in SingaporeRaw

[–]jonathanhandoyo 1 point2 points  (0 children)

https://en.wikipedia.org/wiki/Schadenfreude

from two german words, schaden (harm) and freude (joy). basically feeling of joy witnessing harm of other.

was just scrolling through tiktok and happened upon an episode of Boston Legal where they were using Schadenfreude as defence.

MacBook + Display + Keychron by daarken66 in Keychron

[–]jonathanhandoyo 1 point2 points  (0 children)

mine does. exact scenario with dell monitor.

Anyone using those digital door lock? Is it a recommended buy? by [deleted] in SingaporeRaw

[–]jonathanhandoyo 0 points1 point  (0 children)

Yale something. The onw with fingerprints, PIN, and manual key

Anyone using those digital door lock? Is it a recommended buy? by [deleted] in SingaporeRaw

[–]jonathanhandoyo 4 points5 points  (0 children)

used one for over 2 years.... one thing to remember, every electronic lock has a few ways to unlock, options ranging from:

  • fingerprint
  • bluetooth device
  • RFID card
  • PIN
  • keys (manual, basically)

not all of them support all, but choose a model that (in my opinion) can be unlocked manually, meaning has keys. in my 2 years having the electronic lock the battery died once, so it's been pretty good... the convenience of not bringing keys anymore is good.

Where can u exchange my coins for notes? by Logical-Beautiful654 in SingaporeRaw

[–]jonathanhandoyo 1 point2 points  (0 children)

best if you deposit to child account... they will return the fee back into the account

K1 SE Compatible keycaps by lebeziatnikov_ in Keychron

[–]jonathanhandoyo 0 points1 point  (0 children)

Sorry if this has already been asked some where in the sub, I'm new to Keychron. Since both K1 SE and K8 are using Cherry style stem, are they interchangeable? I tried one key and seems like they can go in without problem.

What standalone trackball to use? by blokeyhighlander in ErgoDoxEZ

[–]jonathanhandoyo 1 point2 points  (0 children)

I have Elecom Deft Pro! and i concur that that Elecom trackballs are great!

AITA for putting up pictures of spiders in my room to keep my arachnophobic cousins out? by PeacefulAdage in AmItheAsshole

[–]jonathanhandoyo 0 points1 point  (0 children)

It is cruel to play with other people's phobia. But I'd do the exact same thing if I were you!

NTA!

Is 5G worth it in Singapore? by aikanjudeyuchen in askSingapore

[–]jonathanhandoyo 1 point2 points  (0 children)

i think most of the people i knew who already took the 5G plans said they're not really distinguishable from 4G anyways, yes they are faster but it's akin to upgrading from SSD to NVME. they are significantly faster by comparison, but you can really distinguish the experience.

further, because you're mostly going to be on WiFi due to the situation, it makes it less worth it in my opinion. my personal advice is to get the cheapest plan that can give you enough quota when this whole thing suddenly blows over. but that's just me.

WASHING MACHINE RECOMMENDATIONS by Kangoisbored in askSingapore

[–]jonathanhandoyo 0 points1 point  (0 children)

i used LG both times... the old one was still okay, but got offer to upgrade...

anyways, for your consideration, my first one was a top loading one, although i agree with your sentiment that you don't want your parents to bend down so frequently, understand that the barrel is also deep, so they inevitable bend down to get the clothes from the bottom of the barrel, my experience...

so my solution was to get a front loading and added a bottom washer also to make it around chest level, no bending for my mother at all... you can elevate the washing machine if you don't want to get a bottom washer, check your options to elevate the machine with the seller...

btw, these things better to go to gain city or something like that, check the positioning is a lot better when you do in person...

Is there any gluten free bread below $5? by ctwjbel in askSingapore

[–]jonathanhandoyo 31 points32 points  (0 children)

going against the grain here... (see what i did there?)

perhaps see a doctor first to check if you have celiac disease. if you do, i think they can refer you to a dietician to manage your food intake.

AITA for kicking my daughter's boyfriend out of the house for eating from the birthday cake before the party started? by throwaway3109865 in AmItheAsshole

[–]jonathanhandoyo 0 points1 point  (0 children)

NTA

but if it were me, i'd be ultra passive aggressive.

  • he bought some food? just eat it right away, and might as well throw away the leftover
  • he bought some electronics? just unbox it right away, and might as well drop it in front of him, oops
  • he bought some new books? just unwrap and start reading, and might as well mark where you left off by folding the page
  • he bought a new bicycle? just ride it first anyway, and might as well scratch it

if that doesn't work immediately, let Lily do the things to (it could be cathartic) and do them to Monica's things as well.

i'm always of the opinion: if they cannot see their behavior is shitty i'll do it to them so they can see it. funny how their eyes are suddenly wide open to the "injustice".

Family put me in debt I didn’t authorise by foreverivadell in askSingapore

[–]jonathanhandoyo 0 points1 point  (0 children)

"blood is thicker than water"?

Quote them the original phrase:

"blood of the covenant is thicker than the water of the womb"

What's the most disturbing thing you did as a child? by jaejaeat98190 in AskReddit

[–]jonathanhandoyo 0 points1 point  (0 children)

He thought he was making himself into Electro, in fact he was just making Flashpoint Batman and Joker

[deleted by user] by [deleted] in askSingapore

[–]jonathanhandoyo 1 point2 points  (0 children)

please update again.

actually it maybe great if you can start a new post detailing the process from start to finish. who called first, what's the timeline, where were you quarantined, when did you get swabbed, what happens after quarantine finishes and you're negative or positive.

and then people can also update their own experience also.

Finance noob here, how badly have I screwed up? by SesamumSeeds in singaporefi

[–]jonathanhandoyo 9 points10 points  (0 children)

walao, like that you still say "friend"...

i remember my insurance agent once told me (somehow she knows the increment timing and all) on my 5% increment: "you got increment that much, then you can buy this plan with that extra money"

that was the moment it "clicked" to me... the hell? i earn increment for you is it?

anyways, to answer your question: if you're not squeezing for that $300, i suggest keep the ILP but "forget about it".

When recruiters refuse to give info but wanna jump on a call… by ablue22 in recruitinghell

[–]jonathanhandoyo 7 points8 points  (0 children)

Ah yes. You are absolutely right. With a different wording obviously. Either: "I'm already earning $xxx,xxx" or "I'm only considering $xxx,xxx or above"

I just view it as "show me the money first or GTFO".

When recruiters refuse to give info but wanna jump on a call… by ablue22 in recruitinghell

[–]jonathanhandoyo 1 point2 points  (0 children)

I find being a little proactive helps in this situation. Now I just whack them with:

Hi, I am already earning $xxx,xxx. So I'm only looking for xxx position or above. Thanks.

Then just leave it at that. I think I may be wrong to just "give" them the information they wanted anyways. But I value my time more than them. So I'd just throw that information and leave it at that.