mirror of
https://github.com/neocities/neocities.git
synced 2025-04-25 01:32:36 +02:00
trying to fix the damn validations
This commit is contained in:
parent
2659e2850d
commit
4e1bf0f73d
2 changed files with 6 additions and 8 deletions
|
@ -74,12 +74,10 @@ class Site < Sequel::Model
|
|||
|
||||
# Check for existing user
|
||||
|
||||
if new?
|
||||
user = self.class.select(:username).filter(username: values[:username]).first
|
||||
if !user.nil? && (user.id != values[:id])
|
||||
errors.add :username, 'This username is already taken. Try using another one.'
|
||||
end
|
||||
end
|
||||
|
||||
if values[:password].nil? || (@password_length && @password_length < MINIMUM_PASSWORD_LENGTH)
|
||||
errors.add :password, "Password must be at least #{MINIMUM_PASSWORD_LENGTH} characters."
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
td Anything you want! It's just HTML. It's your site, your vision. You can make it as normal or crazy as you want. You're the artist, you're in control. Make a site about you, or make it about cats that play Dungeons and Dragons, or make a Daft Punk Fan Site, or a Daft Punk Sucks Site.
|
||||
tr
|
||||
td: b What information can I put on it?
|
||||
td Anything you wan't, as long as it's not illegal to host it in the United States (note to government: stuff that is <i>actually illegal</i>, not just stuff that embarrasses you or reveals your unconstitutional (and hence illegal) spying programs). We don't care if it offends somebody, or you remain anonymous.
|
||||
td Anything you want, as long as it's not illegal to host it in the United States (note to government: stuff that is <i>actually illegal</i>, not just stuff that embarrasses you or reveals your unconstitutional (and hence illegal) spying programs). We don't care if it offends somebody, or you remain anonymous.
|
||||
tr
|
||||
td: b Do I own my content?
|
||||
td Yes, you do. It's yours. We're just giving you a place to host it.
|
||||
|
@ -23,7 +23,7 @@
|
|||
td 10 Megabytes. You can have HTML, Images, Text, CSS, Markdown, and JavaScript. That's it.
|
||||
tr
|
||||
td: b How are you paying for this?
|
||||
td Hopefully with donations. If you feel this is a useful service, help us pay the bills to run it. <a href="/about">Click here to contribute!</a>
|
||||
td With donations. It's not that expensive. If you feel this is a useful service, <a href="/about">click here to contribute!</a>
|
||||
|
||||
.row
|
||||
.span5.offset1
|
||||
|
|
Loading…
Add table
Reference in a new issue