php-imap icon indicating copy to clipboard operation
php-imap copied to clipboard

Shouldn't setMsgn actually be called setSequenceNumber?

Open HelloSebastian opened this issue 3 years ago • 1 comments

Hi @Webklex,

I am confused by the naming of setMsgn or also getMesgn. In the method the position of a message inside the mailbox is set. According to the name in RFC 3501 this number is called "sequence number".

Is there a background why the method was named like this?

As mentioned in https://github.com/Webklex/php-imap/issues/219#issuecomment-1082235952, I would like to make this call for getUID "lazy". This will save us from building the uid_cache. This could then be done directly with the name change.

I'm excited to hear your thoughts on this :)

https://github.com/Webklex/php-imap/blob/6e76b3552491e437f37721ae113129682489c141/src/Message.php#L1380-L1395

HelloSebastian avatar Mar 31 '22 17:03 HelloSebastian

Hi @HelloSebastian , you are absolutely right! Many thanks for the hint :)

Best regards,

Webklex avatar Aug 08 '22 10:08 Webklex