Cleanup() returns null

SOLVED

I have a C# code that integrates with Sage 100 2021 Standard.

After performing some action I want to clean and close the session I opened. for this I'm using:

session.nCleanup();
session.DropObject();

for some reason the nCleanup() returns null instead of 0 as it says in here:

(taken from https://help-sage100.na.sage.com/2022/FLOR/index.htm#Object_Reference/BaseSystem/SY_Session.htm?Highlight=sy_session )

after cleanup() the value of sLastErrorMsg is empty, meaning there was no error, and after calling DropObject() I see in Master Console in Sage that the task was  terminated.

Does anyone knows why it returns null and not 0?