code: def sql_dequote_string(s: str) -> str:
      
      if len(s) < 2:
          # Something wrong.
          return s
      s = s[1:-1]  # strip off the surrounding quotes
      return s.replace("''", "'")
docs: Reverses sql_quote_string.