Created — forked from mickeyren/gist:1542652

Embed URL


SSH clone URL

You can clone with HTTPS or SSH.

Download Gist

weirdness on setting commissions

View gist:1542657
1 2 3 4
# set commission only for non artists or artists whose not buying their own art
Rails.logger.debug '*' * 100
Rails.logger.debug "artist id: #{} product id: #{} (#{!User.current.artist}) || (#{User.current.artist && !User.current.artist.products.include?(li.product)})"
li.set_commissions if !User.current.artist || (User.current.artist && !User.current.artist.products.include?(li.product))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.