Module: CSV::DeleteSuffix (Ruby 2.7.5)
Description: Module : CSV::DeleteSuffix - Ruby 2.7.5

### Home Classes Methods

### In Files

- csv/delete_suffix.rb

### Methods

- #delete_suffix

### Class/Module Index

Quicksearch

- CSV
- CSV::DeleteSuffix
- CSV::FieldsConverter
- CSV::MalformedCSVError
- CSV::MatchP
- CSV::Parser
- CSV::Parser::InputsScanner
- CSV::Parser::InvalidEncoding
- CSV::Parser::Scanner
- CSV::Parser::UnoptimizedStringIO
- CSV::Row
- CSV::Table
- CSV::Writer
- Object

No matching classes.

# CSV::DeleteSuffix

### Public Instance Methods

delete_suffix(suffix) click to toggle source

                   # File csv/delete_suffix.rb, line 8
    def delete_suffix(suffix)
      if end_with?(suffix)
        self[0...-suffix.size]
      else
        self
      end
    end