August 2018
Intermediate to advanced
260 pages
5h 48m
English
There are a number of text conventions used throughout this book.
CodeInText: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: "Open the newly created service object in the app/services/attachments_service.rb file and move the responsibility for uploading the file to the AttachmentsService#upload method."
A block of code is set as follows:
class AttachmentsService def upload(message_id, user_id, file_name, data, media_type) message = Message.find_by!(message_id, user_id: user_id) file = StorageBucket.files.create( key: file_name, body: StringIO.new(Base64.decode64(data), 'rb'), public: true )
Any command-line ...
Read now
Unlock full access