fluid_cli 0.1.6 → 0.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 58ad193f70041410034e5fc3b9e1d5aa53b13dd22b5cf2733d7c3e24a6f608ae
4
- data.tar.gz: 1bf00b84c91d05c142ab94aa021be0752e0071136d6dfedeba6200b9a16f4bc6
3
+ metadata.gz: ef021f6caeb5f09abf1a92b03780f66dd8a3575a75b37e20e233ae28c303bb15
4
+ data.tar.gz: ae2d16ea0c3bb7e706e9b10170e1bec40b00d45a07e7dc71f58a0eb8a3f1f966
5
5
  SHA512:
6
- metadata.gz: a236707efc4f4bf63581f44c05d2d05f49d13b78758a19b3293f9fc77053b6485c4989fd62da78e0e6ad85d76769a2c0e6578f0b46dedcfdb837f920743ce9de
7
- data.tar.gz: 5bc4bb573085cbd9bf6ccb4d50e93bad1aca40ed0760b8c1eee86f941696bed03f3351521206800c0ce7405d5a2f299340f584753b851b9c58cca2d699435a55
6
+ metadata.gz: 77f6bcf3bb9dc1ddf951c0efa9a2a34daac9d37a792e11e33086632133fbd9bcf55df366d6e59ec2b74fae87d9c57bb2427722c890c2f98d892cf826e79c1a73
7
+ data.tar.gz: a67b31ff57cb06cfe123133581138fd34f6c1671ebea4c4cae38597f759b477c154c7ac0eabcd2bcba61b1430f8babf64e852cd439bc64d661545faabb031ec2
@@ -235,9 +235,7 @@ module FluidCLI
235
235
  errors = parsed_body.dig("errors") # either nil or another type
236
236
  errors = errors.dig("asset") if errors&.is_a?(Hash)
237
237
 
238
- message = errors || parsed_body["message"] || exception.message
239
- # Truncate to first lines
240
- [message].flatten.map { |m| m.split("\n", 2).first }
238
+ ["#{parsed_body['error_message']}\n#{errors}"]
241
239
  rescue JSON::ParserError
242
240
  [exception.message]
243
241
  rescue StandardError => e
@@ -398,7 +396,7 @@ module FluidCLI
398
396
  end
399
397
 
400
398
  def backfill_dam_asset_from_imagekit(file, imagekit_response, asset_path_response)
401
- api_client.post(path: "dam/assets/backfill_imagekit", body: JSON.generate({
399
+ payload = {
402
400
  asset: {
403
401
  id: asset_path_response.dig("asset", "id"),
404
402
  imagekit_file_id: imagekit_response.dig("fileId"),
@@ -406,11 +404,13 @@ module FluidCLI
406
404
  mime_type: file.mime_type.name,
407
405
  name: file.name,
408
406
  file_size: imagekit_response.dig("size"),
409
- height: imagekit_response.dig("height"),
410
- width: imagekit_response.dig("width"),
411
407
  expected_path: asset_path_response.dig("asset", "canonical_path")
412
408
  }
413
- }))
409
+ }
410
+
411
+ payload[:asset][:height] = imagekit_response.dig("height") if imagekit_response.dig("height")
412
+ payload[:asset][:width] = imagekit_response.dig("width") if imagekit_response.dig("width")
413
+ api_client.post(path: "dam/assets/backfill_imagekit", body: JSON.generate(payload))
414
414
  end
415
415
 
416
416
 
@@ -1,3 +1,3 @@
1
1
  module FluidCLI
2
- VERSION = "0.1.6"
2
+ VERSION = "0.1.7"
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluid_cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.6
4
+ version: 0.1.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Fluid
8
8
  bindir: exe
9
9
  cert_chain: []
10
- date: 2025-11-26 00:00:00.000000000 Z
10
+ date: 2026-01-09 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: bugsnag