File: user_with_legacy_syntax.rb

package info (click to toggle)
ruby-validate-url 1.0.2%2Bgit-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, buster, forky, sid, trixie
  • size: 172 kB
  • sloc: ruby: 302; makefile: 4
file content (9 lines) | stat: -rw-r--r-- 177 bytes parent folder | download
1
2
3
4
5
6
7
8
9
require 'active_model/validations'

class UserWithLegacySyntax
  include ActiveModel::Validations

  attr_accessor :homepage

  validates_url :homepage, :allow_blank => true
end