P0449 indicates a malfunction detected in the Evaporative Emission Purge (EVAP) solenoid control circuit. That usually means an open or short circuit in the solenoid, connector or wiring. Now that it's working, it's detected a small EVAP leak. That's P0442. You could have a gascap leak, or a leak anywhere in the EVAP system, even the fuel tank. First thing, if I didn't see anything obvious like a cracking EVAP line, is to get the gascap checked by a mechanic with a gascap tester, like at an emissions checking (Smog) station. Or simply replace the cap, that may be easier, depending on your mechanic's mood. You may need to get the code cleared with a scanner, but it should clear up eventually if it's fixed.