Better events handing
Updates net-ptth dependency (fixes #31)