dooray-mail-cli 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/mail-client.js +3 -4
- package/dooray-cli.js +1 -1
- package/package.json +1 -1
package/dist/mail-client.js
CHANGED
|
@@ -332,7 +332,7 @@ class DoorayMailClient {
|
|
|
332
332
|
/**
|
|
333
333
|
* 메일 검색 (키워드, 날짜, 발신자 필터 지원)
|
|
334
334
|
*/
|
|
335
|
-
async searchMail(keywords, options = {}
|
|
335
|
+
async searchMail(keywords, options = {}) {
|
|
336
336
|
let connection;
|
|
337
337
|
try {
|
|
338
338
|
connection = await this.getImapConnection();
|
|
@@ -382,10 +382,9 @@ class DoorayMailClient {
|
|
|
382
382
|
};
|
|
383
383
|
const messages = await connection.search(searchCriteria, fetchOptions);
|
|
384
384
|
|
|
385
|
-
//
|
|
386
|
-
const limitedMessages = messages.slice(0, limit);
|
|
385
|
+
// 제한 없이 모든 검색 결과 반환
|
|
387
386
|
const parsedMails = [];
|
|
388
|
-
for (const item of
|
|
387
|
+
for (const item of messages) {
|
|
389
388
|
const mail = await this.parseImapMessage(item);
|
|
390
389
|
if (mail)
|
|
391
390
|
parsedMails.push(mail);
|
package/dooray-cli.js
CHANGED
|
@@ -752,7 +752,7 @@ async function searchCommand(args) {
|
|
|
752
752
|
if (before) filters.push(`before: ${before}`);
|
|
753
753
|
|
|
754
754
|
console.log(`\n🔍 Search Results (${filters.join(', ')}): ${mails.length} found\n`);
|
|
755
|
-
mails.
|
|
755
|
+
mails.forEach((mail, idx) => {
|
|
756
756
|
const fromText = typeof mail.from === 'object' ? `${mail.from.name} <${mail.from.email}>` : mail.from;
|
|
757
757
|
console.log(`${idx + 1}. [UID: ${mail.uid}] ${fromText}`);
|
|
758
758
|
console.log(` Subject: ${mail.subject}`);
|