coolair
V2EX  ›  问与答

csrf_enabled 被 deprecated 了,应该怎么改啊?!

  •  
  •   coolair · Mar 13, 2017 · 1393 views
    This topic created in 3373 days ago, the information mentioned may be changed or developed.
    https://github.com/lepture/flask-wtf/pull/271

    现在一直报警告:
    FlaskWTFDeprecationWarning: "csrf_enabled" is deprecated and will be removed in 1.0. Set "meta.csrf" instead.

    我代码里有这么一段在 MyForm 的 class 里:
    def __init__(self, csrf_enabled=False, *args, **kwargs):
    ....super(MyForm, self).__init__(csrf_enabled=csrf_enabled, *args, **kwargs)
    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2289 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 16:10 · PVG 00:10 · LAX 09:10 · JFK 12:10
    ♥ Do have faith in what you're doing.