deckhearth/pages/api/collections/[identifier]
Randall Stillwell 560ddcbb8e 🔧 Fix SQL Structure Issues Across All Collection APIs
🐛 Multiple API Fixes:
- Fixed SQL DISTINCT/ORDER BY conflict in thumbnails API
- Fixed SQL result structure (.rows) in cards API
- Fixed SQL result structure (.rows) in permissions API
- Restored accidentally removed code in cards API

 Technical Corrections:
- Removed DISTINCT from thumbnails query to fix ORDER BY conflict
- Updated all APIs to use collectionResult.rows instead of direct access
- Updated all result mappings to use .rows property
- Fixed validation checks to use .rows.length

🎯 Expected Results:
- Thumbnails API should now work without SQL errors
- Cards API should load collection cards properly
- Permissions API should work for collection management
- New card layout thumbnails should display correctly

All collection APIs should now work properly! 🚀
2025-07-27 14:18:49 -05:00
..
activity.js 🔄 Implement Automatic Redirects and Collection Edit/Delete 2025-07-26 22:16:52 -05:00
cards.js 🔧 Fix SQL Structure Issues Across All Collection APIs 2025-07-27 14:18:49 -05:00
permissions.js 🔧 Fix SQL Structure Issues Across All Collection APIs 2025-07-27 14:18:49 -05:00
thumbnails.js 🔧 Fix SQL Structure Issues Across All Collection APIs 2025-07-27 14:18:49 -05:00