code: def check_labml_token_permission(func) -> functools.wraps:
      @functools.wraps(func)
      async def wrapper(*args, **kwargs):
          labml_token = kwargs.get("labml_token", "")
  
          p = project.get_project(labml_token)
          if p and p.is_sharable:
              return await func(*args, **kwargs)
  
          kwargs["labml_token"] = None
  
          return await func(*args, **kwargs)
  
      return wrapper
  
file_path: labml/app/server/labml_app/auth/__init__.py
imports: import functools
  import inspect
  from typing import Optional
  from fastapi import Request
  from fastapi.responses import JSONResponse
  from ..db import project
  from ..db import user
  from ..db.user import User
label_desc: Use image node_id 1 for calling a global function with example usage: check_labml_token_permission(func) and returns: wrapper, unknown, unknown