The examples include checking the return code from various FDS calls immediately after the call.
Only some errors can be detected at the time of the call (for example NULL arg, Not initialized, unaligned address)
It seems that others must wait until the operation is complete ( especially if more than one operation has been queued) as per the callback event which makes this example misleading.
Can you clarify this?
For example WRITING A RECORD:
"The command is queued up, and the success or failure is indicated through event callbacks."
https://infocenter.nordicsemi.com/topic/sdk_nrf5_v17.1.0/lib_fds_usage.html