Express验证程序不断返回错误消息

时间:2019-08-21 01:15:02

标签: validation express postman

我正在使用express-validator来验证名称,电子邮件和密码。路线正在运作。但是,当我在Postmon上对其进行测试时,验证器似乎无法正常工作。即使输入有效的名称,电子邮件和密码,它也会返回400状态错误。

using UnityEngine;

public class Example: MonoBehaviour
{
/*this holds reference to the gameobject it self it needs to be static otherwise each 
instance would have a reference to it self.*/
public static Example instance = null;
//a value (can be whatever)
public float counter = 0.0f;

void Start()
{
    /* if there an already existing Example gameobject (instance isn't null) destroy 
    the others*/
    if (instance != null)
    {
        Destroy(gameObject);
    }
    /*the very first instance is kept as the instance and will run through all the 
    scenes keeping all values until the program is shutdown*/
    else
    {
        DontDestroyOnLoad(gameObject); /*this will keep the gameobject "alive" through all scenes*/
        instance = this; /*instance reference to this gameobject (the first one to exist)*/
    }
}
void Update()
{
  /*adding passing time to counter again this can be any behaviour you want and will 
  keep running through scenes AND the values wont be reset until you shutdown the 
  program*/
  counter += Time.deltaTime;
}
}

0 个答案:

没有答案