Wulf / dsync

Generate rust structs & query functions from diesel schema files
Other
70 stars 13 forks source link

refactor: reduce some clutter #113

Closed hasezoey closed 9 months ago

hasezoey commented 11 months ago

This PR is just a refactor (not affecting output), to reduce possible code-paths, sharing between a feature being enabled or not, mainly reducing clutter

hasezoey commented 10 months ago

let's merge this in but avoid using labels in the future :)

i also dont quite agree with the labels, but it was the only thing to early-return from a block without repeating things multiple times, i guess i will just outsource this to a function and make that function inline(always)

hasezoey commented 10 months ago

@Wulf what do you think about b84b709877f1664e64bf4526cdd496b899b9c332, it is about the same lines in comparison to the original multiple "cfg" but in my opinion cleaner and no "label magic"

Wulf commented 9 months ago

perfect! :)