title: In Ionic 4, trying to send token to Express route, but can't verify token is even in storage
body: <p>I'm trying to send my token in my headers to my Express route, was having trouble, so I wanted to verify that the token was being set in storage.  Having trouble checking this.</p>
  
  <p>authentication.service.ts</p>
  
  <pre><code>  login(user: User): Observable&lt;AuthResponse&gt; {
      return this.httpClient.post(`${this.AUTH_SERVER_ADDRESS}/login`, user).pipe(
        tap(async (res: AuthResponse) =&gt; {
          if (res.user) {
            console.log("res.user:" + res.user.access_token);
            await this.storage.set("ACCESS_TOKEN", res.user.access_token);
            await this.storage.set("EXPIRES_IN", res.user.expires_in);
            this.authenticationState.next(true);
          }
        })
      )
    }
  </code></pre>
  
  <p>The console.log displays <code>undefined</code> for each line.  How can I verify that these values are being set in storage?</p>
  
  <p>The response from the post is:
  <a href="https://i.stack.imgur.com/cm1s0.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/cm1s0.png" alt="enter image description here"></a></p>
  
  <p>Express route:</p>
  
  <pre><code>router.post('/login', (req, res) =&gt; {
      const email = req.body.email;
      const form_password = req.body.password;
      findUserByEmail(email, (err, user) =&gt; {
          if (err) return res.status(500).send({ "message": 'Server error!', "status": '500' });
          if (!user[0]) return res.status(404).send({ "message": 'User not found!', "status": '404' });
          const result = bcrypt.compareSync(form_password, user[0].password);
          if (!result) return res.status(401).send({ "message": 'Password not valid!', "status": '401' });
          const expiresIn = 24 * 60 * 60;
          user[0].access_token = jwt.sign({ id: user[0].id }, process.env.SECRET_KEY, {
              expiresIn: expiresIn
          });
          res.status(200).send({ "user": user, "expires_in": expiresIn, "message": 'Success!', "status": '200' });
      });
  });
  </code></pre>
  
  <pre><code>console.log("res.user:" + JSON.stringify(res.user));
  </code></pre>
  
  <p>results in:</p>
  
  <pre><code>res.user:[{"id":1,"name":"Admin","email":"Admin@test.com","password":"$2a$10$2OaS5CyGKMSF5J8wed5W7.qyNFYrPScBM49SgU7L9MBMVF0RWxx1e","created_at":"2019-10-16T13:28:06.000Z","access_token":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6MSwiaWF0IjoxNTcyNDU1MTk3LCJleHAiOjE1NzI1NDE1OTd9.2eFbQ294TG6gvKUxSyaQGDBEas7ZLFT8k9H7jnpOoXQ"}]```
  </code></pre>