Module: Ompload::Message
Instance Method Summary collapse
- #curl_failed_posting_file(file_path) ⇒ Object
- #invalid_file(file_path) ⇒ Object
- #omploaded(file_path, id) ⇒ Object
- #payload_too_big(file_path, file_size) ⇒ Object
- #progress(file_path) ⇒ Object
- #throttled(file_path) ⇒ Object
Instance Method Details
#curl_failed_posting_file(file_path) ⇒ Object
77 78 79 |
# File 'lib/ompload.rb', line 77 def curl_failed_posting_file(file_path) "error: curl failed to return a response uploading '#{file_path}'" end |
#invalid_file(file_path) ⇒ Object
94 95 96 |
# File 'lib/ompload.rb', line 94 def invalid_file(file_path) "error: '#{file_path}' does not exist or is not a regular file" end |
#omploaded(file_path, id) ⇒ Object
90 91 92 |
# File 'lib/ompload.rb', line 90 def omploaded(file_path, id) "Omploaded '#{file_path}' to #{Omploader.file_url(id)}" end |
#payload_too_big(file_path, file_size) ⇒ Object
98 99 100 101 |
# File 'lib/ompload.rb', line 98 def payload_too_big(file_path, file_size) "error: '#{file_path}' exceeds #{MAX_FILE_SIZE} bytes " << "(size is #{file_size})." end |
#progress(file_path) ⇒ Object
86 87 88 |
# File 'lib/ompload.rb', line 86 def progress(file_path) "Progress for '#{file_path}'" end |
#throttled(file_path) ⇒ Object
81 82 83 84 |
# File 'lib/ompload.rb', line 81 def throttled(file_path) "error: got throttled when trying to ompload '#{file_path}'\n" << "Awaiting 60s and attempting to continue..." end |