fix: increase password length to 4

This commit is contained in:
insects 2025-03-11 15:20:55 +01:00
parent 6710137d9b
commit 901bc36f09

View file

@ -3,7 +3,7 @@ class InstanceController < ApplicationController
zone = create_instance_params
public_id = Nanoid.generate(size: 6)
name = Spicy::Proton.pair(" ")
password = Nanoid.generate(size: 3, alphabet: "0123456789")
password = Nanoid.generate(size: 4, alphabet: "0123456789")
instance = Instance.new(zone: zone, public_id: public_id, name: name, password: password)
if instance.save
@id = instance.public_id