protected function getPaymentFromRequest(HTTPRequest $request, $gateway = null)
    {
        $identifier = $request->param('Identifier');
        $results = $this->extend('updatePaymentFromRequest', $request, $gateway);

        // Look to see if our extension return a payment,
        // if so, return it.
        foreach ($results as $result) {
            if ($result instanceof Payment) {
                return $result;
            }
        }

        return Payment::get()
                ->filter('Identifier', $identifier)
                ->filter('Identifier:not', '')
                ->first();
    }