Fixed bug where http payloads sometimes generated https handler script