Code Duplication    Length = 3-3 lines in 2 locations

lib/Doctrine/DBAL/Driver/SQLAnywhere/SQLAnywhereException.php 2 locations

@@ 45-47 (lines=3) @@
42
     */
43
    public static function fromSQLAnywhereError($conn = null, $stmt = null)
44
    {
45
        if (null !== $conn && ! (is_resource($conn))) {
46
            throw new \InvalidArgumentException('Invalid SQL Anywhere connection resource given: ' . $conn);
47
        }
48
49
        if (null !== $stmt && ! (is_resource($stmt))) {
50
            throw new \InvalidArgumentException('Invalid SQL Anywhere statement resource given: ' . $stmt);
@@ 49-51 (lines=3) @@
46
            throw new \InvalidArgumentException('Invalid SQL Anywhere connection resource given: ' . $conn);
47
        }
48
49
        if (null !== $stmt && ! (is_resource($stmt))) {
50
            throw new \InvalidArgumentException('Invalid SQL Anywhere statement resource given: ' . $stmt);
51
        }
52
53
        $state   = $conn ? sasql_sqlstate($conn) : sasql_sqlstate();
54
        $code    = null;