You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: images_helper.rb
    path of file: ./repos/property_web_builder/app/helpers/pwb
    
    the code of the file until where you have to start completion: module Pwb
  module ImagesHelper
    def bg_image(photo, options = {})
      image_url = 
    
    def bg_image(photo, options = {})
      image_url = get_opt_image_url photo, options
      # style="background-image:linear-gradient( rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.1) ),url(<%= carousel_item.default_photo %>);"
      if options[:gradient]
        "background-image: linear-gradient(#{options[:gradient]}), url(#{image_url});".html_safe
      else
        "background-image: url(#{image_url});".html_safe
      end