Title: Javascript error in media library
Last modified: January 24, 2023

---

# Javascript error in media library

 *  [Jory Hogeveen](https://wordpress.org/support/users/keraweb/)
 * (@keraweb)
 * [3 years, 4 months ago](https://wordpress.org/support/topic/javascript-error-in-media-library/)
 *     ```wp-block-code
       Uncaught TypeError: Cannot read properties of undefined (reading 'length')
           at model.saveCompat (admin-folders.js?ver=2.4.4:153:32)
           at n.save (media-views.min.js?ver=f59f7598bf2f76f17b33ecfe73d83e78:2:20540)
           at n.save (admin-folders.js?ver=2.4.4:180:39)
           at HTMLFormElement.dispatch (jquery.min.js?ver=3.6.1:2:43064)
           at y.handle (jquery.min.js?ver=3.6.1:2:41048)
       ```
   
 * This error occurs when trying to save custom fields from an attachment.

The topic ‘Javascript error in media library’ is closed to new replies.

 * ![](https://ps.w.org/responsive-lightbox/assets/icon-256x256.png?rev=3460874)
 * [Responsive Lightbox & Gallery](https://wordpress.org/plugins/responsive-lightbox/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/responsive-lightbox/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/responsive-lightbox/)
 * [Active Topics](https://wordpress.org/support/plugin/responsive-lightbox/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/responsive-lightbox/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/responsive-lightbox/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [Jory Hogeveen](https://wordpress.org/support/users/keraweb/)
 * Last activity: [3 years, 4 months ago](https://wordpress.org/support/topic/javascript-error-in-media-library/)
 * Status: not resolved