setSplash method

Future<void> setSplash(
  1. File splash, {
  2. String? reason,
})

Set the server's splash.

await server.assets.setSplash(File('splash.png'), reason: 'Testing');

Implementation

Future<void> setSplash(File splash, {String? reason}) async {
  final splashAsset = ImageAsset.makeAsset(splash);
  await _serverPart.updateServer(
      serverId, {'splash': splashAsset.makeUrl()}, reason);
}