文件操作 - no-channel-trailing-slash.ts
返回文件管理
返回主菜单
删除本文件
文件: /var/www/OLD/node_modules/@redocly/openapi-core/src/rules/async3/no-channel-trailing-slash.ts
编辑文件内容
import type { Async3Rule } from '../../visitors'; import type { UserContext } from '../../walk'; import type { Channel } from '../../typings/asyncapi3'; export const NoChannelTrailingSlash: Async3Rule = () => { return { Channel(channel: Channel, { report, location }: UserContext) { if ((channel.address as string).endsWith('/') && channel.address !== '/') { report({ message: `\`${channel.address}\` should not have a trailing slash.`, location: location.key(), }); } }, }; };
修改文件时间
将文件时间修改为当前时间的前一年
删除文件