ReachFive / fake-smtp-server

Fake SMTP Server for email testing
https://www.npmjs.com/package/fake-smtp-server
MIT License
192 stars 81 forks source link

Web interface shows no emails #25

Open mvalenzisi opened 5 years ago

mvalenzisi commented 5 years ago

Hi, after sending the first email, the web interface stops working:

TypeError: Cannot read property 'value' of undefined
    at N (App.js:23)
    at Zi (react-dom.production.min.js:3273)
    at Ra (react-dom.production.min.js:3899)
    at Bo (react-dom.production.min.js:5514)
    at $o (react-dom.production.min.js:5536)
    at Pl (react-dom.production.min.js:5958)
    at Ol (react-dom.production.min.js:5925)
    at xl (react-dom.production.min.js:5860)
    at Ko (react-dom.production.min.js:5787)
    at Object.enqueueSetState (react-dom.production.min.js:2789)
App.js:23 Uncaught (in promise) TypeError: Cannot read property 'value' of undefined
    at N (App.js:23)
    at Zi (react-dom.production.min.js:3273)
    at Ra (react-dom.production.min.js:3899)
    at Bo (react-dom.production.min.js:5514)
    at $o (react-dom.production.min.js:5536)
    at Pl (react-dom.production.min.js:5958)
    at Ol (react-dom.production.min.js:5925)
    at xl (react-dom.production.min.js:5860)
    at Ko (react-dom.production.min.js:5787)
    at Object.enqueueSetState (react-dom.production.min.js:2789)

Messages are still visibile via the api:

$ curl --silent http://localhost:1080/api/emails | jq
[
  {
    "attachments": [],
    "headerLines": [
      {
        "key": "subject",
        "line": "Subject: bla bla"
      },
      {
        "key": "",
        "line": "Hello,"
      },
      {
        "key": "",
        "line": "bla bla bla"
      }
    ],
    "subject": "bla bla",
    "html": false
  }
]
mauricioprado00 commented 4 years ago

Same thing for me, UI is not working...

emreisikligil commented 4 years ago

It was working yesterday. Today, the same thing happened to me. But different error. It happens after sending the first email.

react-dom.production.min.js:4408 TypeError: Cannot read property 'name' of undefined
    at N (App.js:31)
    at Zi (react-dom.production.min.js:3273)
    at Ra (react-dom.production.min.js:3899)
    at Bo (react-dom.production.min.js:5514)
    at $o (react-dom.production.min.js:5536)
    at Pl (react-dom.production.min.js:5958)
    at Ol (react-dom.production.min.js:5925)
    at xl (react-dom.production.min.js:5860)
    at Ko (react-dom.production.min.js:5787)
    at Object.enqueueSetState (react-dom.production.min.js:2789)
cgaspard commented 3 years ago

The problem happens when the email doesn't have all the header fields the UI requires.

https://github.com/ReachFive/fake-smtp-server/pull/39

This will solve the problem when it gets merged in.